Thread (1 message) 1 message, 1 author, 2019-07-15

Re: [PATCH v2 17/35] net/wireless: Use kmemdup rather than duplicating its implementation

From: Kalle Valo <hidden>
Date: 2019-07-15 09:33:46
Also in: linux-wireless, lkml

Fuqian Huang [off-list ref] writes:
kmemdup is introduced to duplicate a region of memory in a neat way.
Rather than kmalloc/kzalloc + memcpy, which the programmer needs to
write the size twice (sometimes lead to mistakes), kmemdup improves
readability, leads to smaller code and also reduce the chances of mistakes.
Suggestion to use kmemdup rather than using kmalloc/kzalloc + memcpy.

Signed-off-by: Fuqian Huang <redacted>
I'm planning to take this.

-- 
Kalle Valo
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help