Pradeep wrote: > Hi , > Iam developing a gldv3 network driver , i often face problems > while detaching my module . When heavy traffic is running on that > interface and if i try to remove the module i end up some buffers not > being returned from the stack . I am failing detach during this buffer held > condition . But is there any way to push the stack to return the completions > > In between i use desballoc for the receive buffers allocation
Allocated buffers may linger "forever." Consider the case where an application is stopped and not reading from a socket. Inbound data will pile up, and eventually encounter flow control. At that point, the buffers just sit on the queue. That's one of the problems with desballoc. You have to arrange for the callback function to hang around until the last one is freed. In theory, the OS could probably help out here, but it'd take some work. When a buffer is placed on a queue, and it has a non-default callback, the system would have to mark the queue as "dirty." In order to force completions, the system would then have to scrub the dirty queues and reallocate (with data copy) any buffers that are lent by someone else. -- James Carlson 42.703N 71.076W <[email protected]> _______________________________________________ networking-discuss mailing list [email protected]
