Re: [PATCH 0/7 v2] net: Fix platform_get_irq's error checking

2017-12-05 Thread Arvind Yadav

Hi Sergei,


On Tuesday 05 December 2017 03:27 PM, Sergei Shtylyov wrote:

On 12/5/2017 12:54 PM, Sergei Shtylyov wrote:


The platform_get_irq() function returns negative number if an error
occurs, Zero if No irq is found and positive number if irq gets 
successful.


No, returning 0 is not a failure indication anymore! It used to 
be but not any longer...


   And I fixed this function exactly to avoid overly complex error 
checks (which you're trying to propose here).


Thanks for your comment. yes you are right. Now It'll not return 0. It 
will return irq and error as negative.

I will not add a check for 0.

platform_get_irq() error checking for only zero is not correct.


[...]


MBR, Sergei

Thank you,
~arvind


Re: [PATCH 0/7 v2] net: Fix platform_get_irq's error checking

2017-12-05 Thread Arvind Yadav

Hi Sergei,


On Tuesday 05 December 2017 03:27 PM, Sergei Shtylyov wrote:

On 12/5/2017 12:54 PM, Sergei Shtylyov wrote:


The platform_get_irq() function returns negative number if an error
occurs, Zero if No irq is found and positive number if irq gets 
successful.


No, returning 0 is not a failure indication anymore! It used to 
be but not any longer...


   And I fixed this function exactly to avoid overly complex error 
checks (which you're trying to propose here).


Thanks for your comment. yes you are right. Now It'll not return 0. It 
will return irq and error as negative.

I will not add a check for 0.

platform_get_irq() error checking for only zero is not correct.


[...]


MBR, Sergei

Thank you,
~arvind


Re: [PATCH 0/7 v2] net: Fix platform_get_irq's error checking

2017-12-05 Thread Sergei Shtylyov

On 12/5/2017 12:54 PM, Sergei Shtylyov wrote:


The platform_get_irq() function returns negative number if an error
occurs, Zero if No irq is found and positive number if irq gets successful.


    No, returning 0 is not a failure indication anymore! It used to be but not 
any longer...


   And I fixed this function exactly to avoid overly complex error checks 
(which you're trying to propose here).



platform_get_irq() error checking for only zero is not correct.


[...]


MBR, Sergei


Re: [PATCH 0/7 v2] net: Fix platform_get_irq's error checking

2017-12-05 Thread Sergei Shtylyov

On 12/5/2017 12:54 PM, Sergei Shtylyov wrote:


The platform_get_irq() function returns negative number if an error
occurs, Zero if No irq is found and positive number if irq gets successful.


    No, returning 0 is not a failure indication anymore! It used to be but not 
any longer...


   And I fixed this function exactly to avoid overly complex error checks 
(which you're trying to propose here).



platform_get_irq() error checking for only zero is not correct.


[...]


MBR, Sergei


Re: [PATCH 0/7 v2] net: Fix platform_get_irq's error checking

2017-12-05 Thread Sergei Shtylyov

On 12/4/2017 8:48 PM, Arvind Yadav wrote:


The platform_get_irq() function returns negative number if an error
occurs, Zero if No irq is found and positive number if irq gets successful.


   No, returning 0 is not a failure indication anymore. It used to be but not 
any longer...



platform_get_irq() error checking for only zero is not correct.


[...]

MBR, Sergei


Re: [PATCH 0/7 v2] net: Fix platform_get_irq's error checking

2017-12-05 Thread Sergei Shtylyov

On 12/4/2017 8:48 PM, Arvind Yadav wrote:


The platform_get_irq() function returns negative number if an error
occurs, Zero if No irq is found and positive number if irq gets successful.


   No, returning 0 is not a failure indication anymore. It used to be but not 
any longer...



platform_get_irq() error checking for only zero is not correct.


[...]

MBR, Sergei


[PATCH 0/7 v2] net: Fix platform_get_irq's error checking

2017-12-04 Thread Arvind Yadav
The platform_get_irq() function returns negative number if an error
occurs, Zero if No irq is found and positive number if irq gets successful.
platform_get_irq() error checking for only zero is not correct.

Removed Other 3 patch which is not related to this series.

Arvind Yadav (7):
  [PATCH 1/7 v2] net: bcmgenet: Fix platform_get_irq's error checking
  [PATCH 2/7 v2] net: ezchip: nps_enet: Fix platform_get_irq's error checking
  [PATCH 3/7 v2] can: xilinx: Fix platform_get_irq's error checking
  [PATCH 4/7 v2] net: ethernet: i825xx: Fix platform_get_irq's error checking
  [PATCH 5/7 v2] net: ethernet: natsemi: Fix platform_get_irq's error checking
  [PATCH 6/7 v2] net: ethernet: smsc: Fix platform_get_irq's error checking
  [PATCH 7/7 v2] net: fjes: Fix platform_get_irq's error checking

 drivers/net/can/xilinx_can.c   | 4 
 drivers/net/ethernet/broadcom/genet/bcmgenet.c | 2 +-
 drivers/net/ethernet/ezchip/nps_enet.c | 4 ++--
 drivers/net/ethernet/i825xx/sni_82596.c| 3 ++-
 drivers/net/ethernet/natsemi/jazzsonic.c   | 5 +
 drivers/net/ethernet/smsc/smc911x.c| 5 +
 drivers/net/fjes/fjes_main.c   | 5 +
 7 files changed, 24 insertions(+), 4 deletions(-)

-- 
2.7.4



[PATCH 0/7 v2] net: Fix platform_get_irq's error checking

2017-12-04 Thread Arvind Yadav
The platform_get_irq() function returns negative number if an error
occurs, Zero if No irq is found and positive number if irq gets successful.
platform_get_irq() error checking for only zero is not correct.

Removed Other 3 patch which is not related to this series.

Arvind Yadav (7):
  [PATCH 1/7 v2] net: bcmgenet: Fix platform_get_irq's error checking
  [PATCH 2/7 v2] net: ezchip: nps_enet: Fix platform_get_irq's error checking
  [PATCH 3/7 v2] can: xilinx: Fix platform_get_irq's error checking
  [PATCH 4/7 v2] net: ethernet: i825xx: Fix platform_get_irq's error checking
  [PATCH 5/7 v2] net: ethernet: natsemi: Fix platform_get_irq's error checking
  [PATCH 6/7 v2] net: ethernet: smsc: Fix platform_get_irq's error checking
  [PATCH 7/7 v2] net: fjes: Fix platform_get_irq's error checking

 drivers/net/can/xilinx_can.c   | 4 
 drivers/net/ethernet/broadcom/genet/bcmgenet.c | 2 +-
 drivers/net/ethernet/ezchip/nps_enet.c | 4 ++--
 drivers/net/ethernet/i825xx/sni_82596.c| 3 ++-
 drivers/net/ethernet/natsemi/jazzsonic.c   | 5 +
 drivers/net/ethernet/smsc/smc911x.c| 5 +
 drivers/net/fjes/fjes_main.c   | 5 +
 7 files changed, 24 insertions(+), 4 deletions(-)

-- 
2.7.4