[Ndiswrapper-general] [PATCH/RFC] ndiswrapper: add ndiswrapper_fix_broken_driver call
Status: Beta
Brought to you by:
pgiri
From: Prarit B. <pr...@sg...> - 2005-05-19 12:07:12
|
Ndiswrapper coders, This patch is an effort to address strange hardware that only supports 30-bit addressing and thus requires that the DMA masks for a particular wireless device be set appropriately. Since there are likely many such "broken" devices out there, I felt it best to implement a broken_driver function call which could fix/modify settings that a driver might assume was set up prior to loading. In the specific case I was dealing with, the Broadcom netbc5 64-bit driver erroneously assumes that the DMA mask on the card has been set prior to loading. In fact, this is not the case and this leads to hangs and other strange behaviour. The fix was in response to a modification made in CVS where GFP_DMA was tagged onto all DMA requests. The GFP_DMA flag requests memory for the DMA transaction below 16M. IMO, while this "works" it is not truly a fix and can lead to performance issues. I am by no means an ndiswrapper expert -- the below is simply an RFC. I've implmented ndiswrapper_fix_broken_driver which is intended to be a list of strcmp's -- one for each known "broken" driver. The comment /* apply other driver's modifications here */ is an indication of how to extend the call. The diff is generated against the ndiswrapper-1.2rc1 source tarball available at sourceforge. Thanks, P. |