summaryrefslogtreecommitdiff
path: root/drivers/usb/gadget
diff options
context:
space:
mode:
authorJingoo Han <jg1.han@samsung.com>2011-05-13 12:27:24 (GMT)
committerGreg Kroah-Hartman <gregkh@suse.de>2011-05-13 22:51:06 (GMT)
commit004c127ef071e33df99708c2778fdb15564962ce (patch)
tree2e1039b0f5c02e98d76cdad887017f58d26096d0 /drivers/usb/gadget
parenta0885924326f79e157847010a9aaf49b058b30dc (diff)
downloadlinux-fsl-qoriq-004c127ef071e33df99708c2778fdb15564962ce.tar.xz
USB: s3c-hsudc: use IS_ERR() instead of NULL check
clk_get() returns ERR_PTR() on error, not NULL. Signed-off-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/gadget')
-rw-r--r--drivers/usb/gadget/s3c-hsudc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/gadget/s3c-hsudc.c b/drivers/usb/gadget/s3c-hsudc.c
index d269019..c339e17 100644
--- a/drivers/usb/gadget/s3c-hsudc.c
+++ b/drivers/usb/gadget/s3c-hsudc.c
@@ -1299,9 +1299,9 @@ static int s3c_hsudc_probe(struct platform_device *pdev)
s3c_hsudc_setup_ep(hsudc);
hsudc->uclk = clk_get(&pdev->dev, "usb-device");
- if (hsudc->uclk == NULL) {
+ if (IS_ERR(hsudc->uclk)) {
dev_err(dev, "failed to find usb-device clock source\n");
- return -ENOENT;
+ return PTR_ERR(hsudc->uclk);
}
clk_enable(hsudc->uclk);