Staging: rts5208: xd: remove unused function xd_check_err_code
PATCH 1/1 Staging: rts5208: xd: remove unused function xd_check_err_code
Remove the function xd_check_err_code as it is not used anywhere in the kernel. Function detected using Coccinelle but removed by hand. Script:
@initialize:python@
@@
def display(name,p):
print(name,p[0].file)
@r1@
identifier func;
type T;
position p;
@@
static T func@p(...)
{
...
}
@r@
identifier r1.func;
@@
func
@script:python depends on !r@
func << r1.func;
p << r1.p;
@@display(func,p)
--- drivers/staging/rts5208/xd.c | 7 ------- 1 file changed, 7 deletions(-)
drivers/staging/rts5208/xd.c +0 -7
@@ -42,13 +42,6 @@ static inline void xd_set_err_code(struct rtsx_chip *chip, u8 err_code) xd_card->err_code = err_code; } -static inline int xd_check_err_code (struct rtsx_chip *chip,u8 err_code) -{ -struct xd_info *xd_card = &(chip->xd_card); - -return (xd_card->err_code == err_code); -} -static int xd_set_init_para (struct rtsx_chip *chip) {struct xd_info *xd_card = &(chip->xd_card);
Signature · 1 line
1.9.1
Greg KH
maintainerQuoted 30 lines · Bhumika Goyal
Remove the function
xd_check_err_codeas it is not used anywhere in the kernel. Function detected using Coccinelle but removed by hand. Script:@initialize:python@
@@
defdisplay(name,p):print(name,p[0].file)@r1@
identifier func;
type T;
position p;
@@
static T func@p(...)
{
...
}@r@
identifier r1.func;
@@
func@script:python depends on !r@
func << r1.func;
p << r1.p;
@@display(func,p)
Quoted 4 lines
Signed-off-by Bhumika Goyal <[email protected]>--- drivers/staging/rts5208/xd.c | 7 ------- 1 file changed, 7 deletions(-)
Patch does not apply to my tree :(