简体   繁体   English

使用iokit框架在mac os x中以编程方式创建块设备

[英]creating a block device programmatically in mac os x using iokit framework

As i am a total noob to mac os x programming i am having some problems understanding this.I want to create a block device in mac os x leopard which would act as a normal drive in mac os x and after that i want to define the geometry of that device or drive according to a drive which i created during installation. 由于我是Mac OS X编程的入门者,因此我对此有一些了解。我想在Mac OS X Leopard中创建一个块设备,该设备将作为Mac OS X中的普通驱动器,之后我要定义该设备或驱动器的几何形状取决于我在安装过程中创建的驱动器。 As i am using xcode and want to do driver development so i am using iokit framework. 由于我正在使用xcode并希望进行驱动程序开发,因此我正在使用iokit框架。 Can anyone tell me which header files and API`s should i use to accomplish this task. 谁能告诉我应该使用哪些头文件和API来完成此任务。 Any help would be appreciated. 任何帮助,将不胜感激。 Please help me!!! 请帮我!!! Ironhide707. Ironhide707。

You want the IOStorage subsystem of IOKit. 您需要IOKit的IOStorage子系统。 The easiest way to get started is to create a filter scheme driver: http://developer.apple.com/library/mac/#documentation/DeviceDrivers/Conceptual/MassStorage/08_Media_Example/MS_Media_Example.html 最简单的入门方法是创建过滤器方案驱动程序: http : //developer.apple.com/library/mac/#documentation/DeviceDrivers/Conceptual/MassStorage/08_Media_Example/MS_Media_Example.html

The book "Mac OS X Internals" by Amit Singh also contains some info and an example on this (source available at http://osxbook.com/ ). 阿米特·辛格(Amit Singh)撰写的《 Mac OS X Internals》一书也包含一些信息和示例(可从http://osxbook.com/获得源代码)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM