[PATCH] ARM: davinci: dm646x: Convert LEDs to GPIO descriptor table

Sekhar Nori nsekhar at ti.com
Tue Sep 8 00:18:22 EDT 2020


Hi Linus,

On 04/09/20 1:19 AM, Linus Walleij wrote:
> On Thu, Sep 3, 2020 at 8:21 AM Sekhar Nori <nsekhar at ti.com> wrote:
> 
>> With this patch, I see during boot:
>>
>> leds-gpio leds-gpio.0: cannot find GPIO chip 1-0038, deferring
> 
> How annoying :(
> 
> Yet this is in the boot log:
> 
> pcf857x 1-0038: probed
> 
> And when I look inte pcf857x driver I see this:
> 
> gpio->chip.label = client->name;
> 
> So it "should" be named "1-0038".
> 
> Can you check in /sys/kernel/debug/gpio what name this
> GPIO chip actually gets?

Here is the output. With patches applied:

# cat /sys/kernel/debug/gpio                                      
gpiochip0: GPIOs 0-70, parent: platform/davinci_gpio, davinci_gpio:             
 gpio-43  (                    |scl                 ) out lo                    
 gpio-44  (                    |sda                 ) in  lo                    
                                                                                
gpiochip1: GPIOs 144-151, parent: i2c/1-0038, pcf8574, can sleep:               
                                                                                
gpiochip2: GPIOs 152-159, parent: i2c/1-0039, pcf8574, can sleep:               
 gpio-153 (                    |pll_sr              ) out lo                    
 gpio-154 (                    |pll_fs1             ) out lo                    
 gpio-155 (                    |pll_fs2             ) out lo                    
 gpio-159 (                    |user_sw             ) in  hi                    
                                                                                
gpiochip3: GPIOs 160-167, parent: i2c/1-003a, pcf8574, can sleep:               
 gpio-160 (                    |nDRV_VBUS           ) out hi                    
 gpio-161 (                    |VDDIMX_EN           ) out hi                    
 gpio-162 (                    |VLYNQ_EN            ) out hi                    
 gpio-163 (                    |nCF_RESET           ) out lo                    
 gpio-165 (                    |WLAN_RESET          ) out hi                    
 gpio-166 (                    |nATA_SEL            ) out lo                    
 gpio-167 (                    |nCF_SEL             ) out hi           


Without patches applied:

# cat /sys/kernel/debug/gpio                                      
gpiochip0: GPIOs 0-70, parent: platform/davinci_gpio, davinci_gpio:             
 gpio-43  (                    |scl                 ) out lo                    
 gpio-44  (                    |sda                 ) in  lo                    
                                                                                
gpiochip1: GPIOs 144-151, parent: i2c/1-0038, pcf8574, can sleep:               
 gpio-144 (                    |DS8                 ) out hi ACTIVE LOW         
 gpio-145 (                    |DS7                 ) out hi ACTIVE LOW         
 gpio-146 (                    |DS6                 ) out hi ACTIVE LOW         
 gpio-147 (                    |DS5                 ) out hi ACTIVE LOW         
 gpio-148 (                    |DS4                 ) out hi ACTIVE LOW         
 gpio-149 (                    |DS3                 ) out hi ACTIVE LOW         
 gpio-150 (                    |DS2                 ) out hi ACTIVE LOW         
 gpio-151 (                    |DS1                 ) out hi ACTIVE LOW         
                                                                                
gpiochip2: GPIOs 152-159, parent: i2c/1-0039, pcf8574, can sleep:               
 gpio-153 (                    |pll_sr              ) out lo                    
 gpio-154 (                    |pll_fs1             ) out lo                    
 gpio-155 (                    |pll_fs2             ) out lo                    
 gpio-159 (                    |user_sw             ) in  hi                    
                                                                                
gpiochip3: GPIOs 160-167, parent: i2c/1-003a, pcf8574, can sleep:               
 gpio-160 (                    |nDRV_VBUS           ) out hi                    
 gpio-161 (                    |VDDIMX_EN           ) out hi                    
 gpio-162 (                    |VLYNQ_EN            ) out hi                    
 gpio-163 (                    |nCF_RESET           ) out lo                    
 gpio-165 (                    |WLAN_RESET          ) out hi                    
 gpio-166 (                    |nATA_SEL            ) out lo                    
 gpio-167 (                    |nCF_SEL             ) out hi                    

Thanks,
Sekhar



More information about the linux-arm-kernel mailing list