platform bus, usage?

From: Pierre Ossman
Date: Sun Aug 22 2004 - 15:47:08 EST


I'm in the process of writing a driver for a SD/MMC card reader. Since this is the first driver I'm writing I'm having some difficulties fitting it into the linux driver model. I've read all the documentation I can find to no avail.

The device is attached to the LPC bus and cannot be found using PNP. From what I can gather this driver should therefore be organised under the platform bus. I can't figure out how to do this though. I've created the device structure, with platform_bus_type at .bus. I've called device_register with the structure. Now how to I create a device object and attach this to the bus? With PCI I guess this handles itself using the PCI id:s.

At the moment I just let the driver play by itself. But that doesn't seem to be using the driver model properly.

Any pointers would be helpful. Documentation, functions, example drivers, anything.

Rgds
Pierre Ossman

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/