diff options
author | Sachin Kamat <sachin.kamat@linaro.org> | 2012-09-03 06:18:20 -0400 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2012-09-03 10:09:37 -0400 |
commit | dc2cdcaf4caafeb069d01704fdfda24f9c1f443a (patch) | |
tree | f2959da3428ce99490dcfa89598fbb211c19b407 /drivers | |
parent | affaab4c58d8e5f7c30ca2be351277cf72d2336f (diff) |
usb: gadget: s3c-hsudc: Replace 0 with NULL for pointers
Silences the following type of sparse warnings:
warning: Using plain integer as NULL pointer
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/usb/gadget/s3c-hsudc.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/usb/gadget/s3c-hsudc.c b/drivers/usb/gadget/s3c-hsudc.c index 35cdc6a5a589..d8e785d4ad59 100644 --- a/drivers/usb/gadget/s3c-hsudc.c +++ b/drivers/usb/gadget/s3c-hsudc.c | |||
@@ -835,7 +835,7 @@ static struct usb_request *s3c_hsudc_alloc_request(struct usb_ep *_ep, | |||
835 | 835 | ||
836 | hsreq = kzalloc(sizeof(*hsreq), gfp_flags); | 836 | hsreq = kzalloc(sizeof(*hsreq), gfp_flags); |
837 | if (!hsreq) | 837 | if (!hsreq) |
838 | return 0; | 838 | return NULL; |
839 | 839 | ||
840 | INIT_LIST_HEAD(&hsreq->queue); | 840 | INIT_LIST_HEAD(&hsreq->queue); |
841 | return &hsreq->req; | 841 | return &hsreq->req; |
@@ -904,16 +904,16 @@ static int s3c_hsudc_queue(struct usb_ep *_ep, struct usb_request *_req, | |||
904 | csr = readl((u32)hsudc->regs + offset); | 904 | csr = readl((u32)hsudc->regs + offset); |
905 | if (!(csr & S3C_ESR_TX_SUCCESS) && | 905 | if (!(csr & S3C_ESR_TX_SUCCESS) && |
906 | (s3c_hsudc_write_fifo(hsep, hsreq) == 1)) | 906 | (s3c_hsudc_write_fifo(hsep, hsreq) == 1)) |
907 | hsreq = 0; | 907 | hsreq = NULL; |
908 | } else { | 908 | } else { |
909 | csr = readl((u32)hsudc->regs + offset); | 909 | csr = readl((u32)hsudc->regs + offset); |
910 | if ((csr & S3C_ESR_RX_SUCCESS) | 910 | if ((csr & S3C_ESR_RX_SUCCESS) |
911 | && (s3c_hsudc_read_fifo(hsep, hsreq) == 1)) | 911 | && (s3c_hsudc_read_fifo(hsep, hsreq) == 1)) |
912 | hsreq = 0; | 912 | hsreq = NULL; |
913 | } | 913 | } |
914 | } | 914 | } |
915 | 915 | ||
916 | if (hsreq != 0) | 916 | if (hsreq) |
917 | list_add_tail(&hsreq->queue, &hsep->queue); | 917 | list_add_tail(&hsreq->queue, &hsep->queue); |
918 | 918 | ||
919 | spin_unlock_irqrestore(&hsudc->lock, flags); | 919 | spin_unlock_irqrestore(&hsudc->lock, flags); |