paride: fix a return in pd_detect()
Subsystems (2)
PATCH 1/1 paride: fix a return in pd_detect()
In this function returning non-zero means the hardware was detected and zero means it wasn't. This is a failure path so we should return zero.
Fixes 9f4ba6b05869 ('paride: use new parport device model')
Signed-off-by Dan Carpenter <[email protected]>
drivers/block/paride/pd.c +1 -1
@@ -877,7 +877,7 @@ static int pd_detect(void) par_drv =pi_register_driver (name);if (!par_drv) {pr_err ("failed to register %s driver\n" , name); -return -1 ; +return 0 ; }if (pd_drive_count =0 ) {/* nothing spec'd - so autoprobe for 1 */
Quoted 5 lines · Dan Carpenter
In this function returning non-zero means the hardware was detected and zero means it wasn't. This is a failure path so we should return zero.
Fixes 9f4ba6b05869 ('paride: use new parport device model')Signed-off-by Dan Carpenter <[email protected]>
Acked-by Sudip Mukherjee <[email protected]>
regards
sudip