From 004c127ef071e33df99708c2778fdb15564962ce Mon Sep 17 00:00:00 2001 From: Jingoo Han Date: Fri, 13 May 2011 21:27:24 +0900 Subject: USB: s3c-hsudc: use IS_ERR() instead of NULL check clk_get() returns ERR_PTR() on error, not NULL. Signed-off-by: Jingoo Han Signed-off-by: Greg Kroah-Hartman --- drivers/usb/gadget/s3c-hsudc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'drivers/usb/gadget/s3c-hsudc.c') diff --git a/drivers/usb/gadget/s3c-hsudc.c b/drivers/usb/gadget/s3c-hsudc.c index d26901932a5c..c339e171eacb 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); -- cgit v1.2.1