platform, pnp and mmc bus
David Zeuthen
david at fubar.dk
Sat Jan 29 12:23:45 PST 2005
On Sat, 2005-01-29 at 02:00 +0100, Pierre Ossman wrote:
> I'm trying to make the necessary additions to HAL to allow it to detect
> mmc cards. This has proven to be a bit more work than I first thought.
>
I'm not sure exactly what you mean by mmc cards? Can you clarify a bit
more?
> Step 1:
>
> The MMC cards reside on their own bus, so I need to add a new bus type.
> Using the other bus handlers in hal this wasn't too difficult.
>
Right.
> Step 2:
>
> Devices too deep in the sysfs structure are expected to have a parent
> already in the hal tree. This was not true for my mmc controller since
> it is a lpc device. So it seemed I had to fix that into the tree first.
> Studying the platform bus handler I found that it is hardcoded to only
> accept floppy drives. A couple of if:s around critical sections and I
> got it accepting all platform devices.
>
> This got it fairly up and running. I got the controller in the tree and
> mmc cards, including their block devices, were correctly detected.
> Then I ran into some more problems. The driver can also be used in PNP
> mode, which means it shows up in the pnp bus. So I guess there'll be a:
>
> Step 3:
>
> Create a pnp bus handler.
>
This already exists on HEAD.
> Now for the actual questions. So far I've just been playing around to
> get my stuff working and it's a bit of a mess. Has anyone looked at
> these problems and perhaps already has a plan for handling them?
> Otherwise I could continue working on it and get a more clean version.
>
> The pnp is also a problem. It doesn't really correspond to a physical
> bus (platform doesn't really either, but it's closer at least). But pnp
> devices are in every case I can think of, devices that belong on the
> platform bus. So should the pnp bus be a seperate bus in hal or should
> we try to group it with the platform bus?
>
Not sure until I understand the problem domain yet. Can you possibly
post
the output of 'tree /sys' and describe how it works today?
Thanks,
David
_______________________________________________
hal mailing list
hal at lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/hal
More information about the Hal
mailing list