Messages in this thread | | | Date | Sun, 01 Mar 2009 19:28:01 +0100 | From | Éric Piel <> | Subject | Re: lis3's ACPI dependency |
| |
Daniel Mack schreef: > Hi Pavel, Eric, > > are there any plans to free the lis3 driver from its ACPI dependency? > In fact, this device is I2C/SPI connected which the ACPI layer seems to > hide from the driver, but to use it on embedded devices, the bus drivers > must be used directly and the dependeny seems entirely unnecessary > anyway. > > Also I got the feeling that using a globally exported 'adev' symbol all > over the different layers is not the best practice - I suspect all the > occasions could be solved with private pointers and/or container_of(). > Isn't there any cleanup pending? Hi Daniel, Actually, the hp_accel.c file is dedicated to the acpi part. The lis3lv02d.c file is supposed to be bus agnostic. In practice I agree it's not completely true, but this is mainly because for now there is only one bus supported (ACPI) and therefore the work for making it completely bus-independent is not yet worthy. As soon as someone is interested in writing a I²C/SPI interface it will become much more apparent what has to be generalized.
Indeed, as you noticed, the main work left to do is to generalize acpi_lis3lv02d (adev) to something ACPI independent. I'd say this could be done simply by changing the signature of the four callback functions and having device being just a void*.
If you are willing to write one of the I²C/SPI interfaces, I'll be happy to support you.
See you, Eric
-- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |