Subject: Re: Layered device driver question
To: Constantine Sapuntzakis <>
From: Ignatios Souvatzis <>
List: tech-kern
Date: 09/22/1999 21:43:42
On Wed, Sep 22, 1999 at 11:48:16AM -0700, Constantine Sapuntzakis wrote:
> I've got a device driver that would like to pass an ioctl request
> to its parent. What is the best way of doing this?

IMO, the device would need knowledge about itself and its parent, and the
parent, too, so calling either a fixed name ___ioctl() in the parent, or
keeping a pointer to that function in the parents' softc structure would
be the right thing to do. (You can access your parents' softc... your
struct device contains a parent pointer, and for a given sort of device,
you know where in the softc the struct device is embedded.).

Of course, not knowing what you want to do, take this with a grain of salt.