Fix checkpatch warning:
WARNING: debugfs_remove_recursive(NULL) is safe this check is probably not required
Cc: Ralf Baechle <[email protected]>
Cc: [email protected]
Signed-off-by: Fabian Frederick <[email protected]>
---
arch/mips/cavium-octeon/oct_ilm.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/arch/mips/cavium-octeon/oct_ilm.c b/arch/mips/cavium-octeon/oct_ilm.c
index 71b213d..2d68a39 100644
--- a/arch/mips/cavium-octeon/oct_ilm.c
+++ b/arch/mips/cavium-octeon/oct_ilm.c
@@ -194,8 +194,7 @@ err_irq:
static __exit void oct_ilm_module_exit(void)
{
disable_timer(TIMER_NUM);
- if (dir)
- debugfs_remove_recursive(dir);
+ debugfs_remove_recursive(dir);
free_irq(OCTEON_IRQ_TIMER0 + TIMER_NUM, 0);
}
--
1.8.4.5
On 06/29/2014 12:16 AM, Fabian Frederick wrote:
> Fix checkpatch warning:
> WARNING: debugfs_remove_recursive(NULL) is safe this check is probably not required
>
> Cc: Ralf Baechle <[email protected]>
> Cc: [email protected]
> Signed-off-by: Fabian Frederick <[email protected]>
I haven't tested it, but it seems fine, so...
Acked-by: David Daney <[email protected]>
> ---
> arch/mips/cavium-octeon/oct_ilm.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/arch/mips/cavium-octeon/oct_ilm.c b/arch/mips/cavium-octeon/oct_ilm.c
> index 71b213d..2d68a39 100644
> --- a/arch/mips/cavium-octeon/oct_ilm.c
> +++ b/arch/mips/cavium-octeon/oct_ilm.c
> @@ -194,8 +194,7 @@ err_irq:
> static __exit void oct_ilm_module_exit(void)
> {
> disable_timer(TIMER_NUM);
> - if (dir)
> - debugfs_remove_recursive(dir);
> + debugfs_remove_recursive(dir);
> free_irq(OCTEON_IRQ_TIMER0 + TIMER_NUM, 0);
> }
>
>