diff options
author | Eric Sesterhenn <snakebyte@gmx.de> | 2006-10-01 08:28:09 +0200 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-10-01 09:39:24 +0200 |
commit | 397d6140e93156ecb9cafcd9be0db10ff3c12ab3 (patch) | |
tree | d24bdacaf4fd31cbddc684e4b3d9d216911b4c2d /drivers/rtc/rtc-v3020.c | |
parent | [PATCH] Remove BUG_ON(unlikely) in include/linux/aio.h (diff) | |
download | linux-397d6140e93156ecb9cafcd9be0db10ff3c12ab3.tar.xz linux-397d6140e93156ecb9cafcd9be0db10ff3c12ab3.zip |
[PATCH] Remove unnecessary check in drivers/rtc/rtc-v3020.c
Looks like the probe function always gets a valid pdev, and checking it
after dereferencing it is pretty useless. This patch removes the check
(cid #1365)
Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Cc: Raphael Assenat <raph@raphnet.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/rtc/rtc-v3020.c')
-rw-r--r-- | drivers/rtc/rtc-v3020.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/rtc/rtc-v3020.c b/drivers/rtc/rtc-v3020.c index a40f400acff6..e28cc4b0901a 100644 --- a/drivers/rtc/rtc-v3020.c +++ b/drivers/rtc/rtc-v3020.c @@ -169,9 +169,6 @@ static int rtc_probe(struct platform_device *pdev) if (pdev->resource[0].flags != IORESOURCE_MEM) return -EBUSY; - if (pdev == NULL) - return -EBUSY; - chip = kzalloc(sizeof *chip, GFP_KERNEL); if (!chip) return -ENOMEM; |