I have an wireless network driver for Nuclues. I need to know the usage of MEM_Buffer_Dequeue & MEM_Buffer_Enqueue usage. The driver works fine for few 40 iteration(ping). Then i get an Memory access violation in the recieve function When i say transmit i dequeue an net buffer from free list.[ pNetBuf= MEM_Buffer_Dequeue(&MEM_Buffer_Freelist)] After transmit is done in my transmit done call back i call [ MEM_Buffer_Enqueue( &MEM_Buffer_Freelist, pNetBuf) ] in the recieve i call MEM_Buffer_Enqueue (&MEM_Buffer_List, pNetBuf) pNetBuf is the netbuffer recieved. & notify the OS using NU_Set_Events(&Buffers_Available, (UNSIGNED)2,NU_OR) after recieve is DONE!!!! I have doubt in the flow. Is this a correct method of handling the buffer and freelist. Is there any better way to do the transmit & recieve. Any suggestion is appreciated. Thanks in advance
Nuclues Net Buffer
Started by ●March 31, 2007