[PATCH] component: replace ternary operator with min()

2022-07-12 Thread Jiangshan Yi
From: Jiangshan Yi Fix the following coccicheck warning: drivers/base/component.c:544: WARNING opportunity for min(). drivers/base/component.c:740: WARNING opportunity for min(). min() macro is defined in include/linux/minmax.h. It avoids multiple evaluations of the arguments when non-constant

Re: [PATCH] component: replace ternary operator with min()

2022-07-12 Thread Greg KH
On Tue, Jul 12, 2022 at 03:12:23PM +0800, Jiangshan Yi wrote: > From: Jiangshan Yi > > Fix the following coccicheck warning: > > drivers/base/component.c:544: WARNING opportunity for min(). > drivers/base/component.c:740: WARNING opportunity for min(). > > min() macro is defined in