tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

why is this needed?

gscpcib(4) in it's current state does not work. it does not attach the GPIO part. I had to apply the attached diff to make it work, but I really wonder why this is needed...

When I leave out the device_t sc_dev part in struct gscpcib_softc, i.e. I do not have this structure member, but the rest of the diff, then the gpio will attach, but accessing with e.g. 'gpioctl gpio0 6 set out' will lead to an uvm_map error an beam the machine to the eternal hunting grounds... (aka panic).

Something(tm) must be modifying the gscpcib_softc structure in the attach routine, around pcibattach(). Setting the sc->sc_gpio_present to true, then calling pcibattach(), and after this, sc- >sc_gpio_present is not longer true. I don't want to committ my fix right away, I'd really like to understand what is going on here.

hints appreciated...    - Marc Balmer

Attachment: gscpcib_01.diff
Description: Binary data

Home | Main Index | Thread Index | Old Index