Is it possible to code a device driver in Java?

后端 未结 13 1251
猫巷女王i
猫巷女王i 2020-12-04 20:04

Introduction

I heard something about writing device drivers in Java (heard as in \"with my ears\", not from the internet) and was wondering... I always thought dev

13条回答
  •  一生所求
    2020-12-04 20:54

    Device drivers have to be written in a language which can execute in the kernel, either compiled into it, or loaded as a module at runtime. This usually precludes writing device drivers in Java, but I suppose you theoretically could implement a JVM inside a device driver and let it execute Java code. Not that any sane person would want to do that.

    On Linux there are several user-land (i.e. non-kernel) implementations of filesystems which uses a common abstraction layer called (fuse) which allows user-land programs to implement things which are typically done in the kernel.

提交回复
热议问题