* Tony Lindgren [080916 16:14]: > * Tony Lindgren [080913 10:12]: > > * Russell King - ARM Linux [080913 03:00]: > > > On Thu, Sep 11, 2008 at 05:48:49PM -0700, Tony Lindgren wrote: > > > > > > Maybe these functions should also be taking note of info->nr_slots? > > > Though I don't particularly like the way 'info' is shared between both > > > controllers. It's more usual to pass a data structure to drivers > > > describing just the data for _this_ instance of the device. > > > > Let's see if that can be sorted out too. Some implementations multiplex > > the slot over I2C. > > > > > Now, when you come across a device with three controllers, you're not > > > modifying arch/arm/plat-omap/devices.c to add that third controller - > > > you're just creating the omapN_init_mmc() function with another > > > omap_mmc_add() line. > > > > > > As an added bonus, notice the lack of nasty #ifdef's scattered in there > > > as well. > > > > Yeah that's good. > > > > > Oh, and I see little reason for checking for NULL data in these functions - > > > they clearly don't take NULL data, and if someone passes NULL data, they > > > deserve to oops - and hopefully they'll fix their code. > > > > OK > > Here's the patch updated. If necessary, the patch could be broken into > several parts. > > Turns out that the omap1 MMC support has been pretty badly broken for > a while now. I ended up removing all the obviously broken MMC > configurations, and only try to revive the ones that seem like > they should work. I also removed the cover switch handling that needs > to be reimplemented using gpio chip instead. Here's the patch with few compile and whitespace warnings fixed. > Regards, > > Tony