On Thu, Jan 23, 2020 at 10:48:06AM +0900, Lee B wrote: > On Tue Jan 14, 2020 at 5:59 PM, Claudio Jeker wrote: > > > > Since the credentials should not be passed back to userland I would not > > add them to struct umb_parameter but instead to struct umb_softc. > > Then you don't need to use struct umb_parameter for the ioctl and > > instead > > could just pass the (utf16) string to the kernel. > > Apart form that it looks good. > > > > > > OK, the umb_softc part was straightforward enough, thanks. I'd like > some advice on how to handle the ifconfig(8) changes to accomodate > this though. I see the wifi code appears to use a separate ioctl pair > to handle the authentication credentials (WPA/PSK). Is this the right > way to go, or have I missed an easier solution? >
No that is the best way. Create a new ioctl to set the data. You can decide if you want to pass the data together ot split in two commands. I think a single ioctl has benefits for the driver but is more annoying to handle in ifconfig. -- :wq Claudio