Re: [PATCH v4 15/16] leds: Add common LED binding parsing support to LED class/core

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello All,

On Mon, 2019-11-18 at 08:59 +0300, Dan Carpenter wrote:
> Hi Matti,
> 
> [auto build test WARNING on 31f4f5b495a62c9a8b15b1c3581acd5efeb9af8c]
> 
> url:    
> https://github.com/0day-ci/linux/commits/Matti-Vaittinen/Support-ROHM-BD71828-PMIC/20191117-030515
> base:    31f4f5b495a62c9a8b15b1c3581acd5efeb9af8c
> 
> If you fix the issue, kindly add following tag
> Reported-by: kbuild test robot <lkp@xxxxxxxxx>
> Reported-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> 
> smatch warnings:
> drivers/leds/led-core.c:400 fw_is_match() error: uninitialized symbol
> 'ret'.
> drivers/leds/led-core.c:465 led_find_fwnode() error: double free of
> 'val'

Ouch. The free is clearly a leftover from original code where the
"is_match" was not it's own function. Sorry folks. I'll fix both issues
and send new version.

By the way, I'd appreciate if someone else would also check the
reference-counting for fwnodes - is pumping up the refcount in
led_find_fwnode Ok? My idea is that when-ever the led_find_fwnode
returns an fwnode, the LED class needs to decrease refcount when LED is
unregistered. No matter if fwnode was from device, given by LED driver
or found by the LED class.

Br,
	Matti Vaittinen






[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux