[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <2026012715-cottage-unsterile-00c2@gregkh>
Date: Tue, 27 Jan 2026 15:44:49 +0100
From: Greg KH <gregkh@...uxfoundation.org>
To: Minu Jin <s9430939@...er.com>
Cc: dan.carpenter@...aro.org, andy@...nel.org,
linux-staging@...ts.linux.dev, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] staging: rtl8723bs: Remove wrapper functions in
osdep_service
On Sun, Jan 25, 2026 at 12:41:45AM +0900, Minu Jin wrote:
> Remove unnecessary wrapper functions _rtw_malloc, _rtw_zmalloc,
> _rtw_skb_alloc, and _rtw_skb_copy from osdep_service.c.
Please do these one at a time, as doing this all at once is impossible
to review and verify.
> These wrappers were using 'in_interrupt()' to determine allocation flags,
> which is unreliable and discouraged.
>
> Callers have been updated to use standard kernel functions directly:
> - _rtw_malloc() -> kmalloc()
> - _rtw_zmalloc() -> kzalloc()
> - _rtw_skb_alloc() -> __dev_alloc_skb()
> - _rtw_skb_copy() -> skb_copy()
>
> All call sites have been manually reviewed and converted to kzalloc, kmalloc.
> The GFP flags were chosen based on the calling context:
> - GFP_ATOMIC is used for atomic contexts. (irq handler, holding
> spinlock)
> - GFP_KERNEL is used for initialization, configuration, and command paths.
How did you validate the calling contexts?
thanks,
greg k-h
Powered by blists - more mailing lists