diff options
author | Peter Huewe <PeterHuewe@gmx.de> | 2011-01-30 22:33:01 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-03-22 02:32:19 +0300 |
commit | 61ca1500c5ee04f2be34a4f58bb9baed0214b7a9 (patch) | |
tree | ef71d383209c305352710cfac4a34fe068886af6 /drivers/media/video/saa7164/saa7164-dvb.c | |
parent | 7ee9e64a3d7379fd443090880158374181f754cf (diff) | |
download | linux-61ca1500c5ee04f2be34a4f58bb9baed0214b7a9.tar.xz |
[media] video/saa7164: Fix sparse warning: Using plain integer as NULL pointer
This patch fixes the warning "Using plain integer as NULL pointer",
generated by sparse, by replacing
if (var == 0)
with
if (!var)
after an allocation
and all other offending 0s with NULL.
KernelVersion: linus' tree-1f0324c
Signed-off-by: Peter Huewe <peterhuewe@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/saa7164/saa7164-dvb.c')
-rw-r--r-- | drivers/media/video/saa7164/saa7164-dvb.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/video/saa7164/saa7164-dvb.c b/drivers/media/video/saa7164/saa7164-dvb.c index b305a01b3bde..f65eab63ca87 100644 --- a/drivers/media/video/saa7164/saa7164-dvb.c +++ b/drivers/media/video/saa7164/saa7164-dvb.c @@ -309,8 +309,8 @@ static int dvb_register(struct saa7164_port *port) port->hw_streamingparams.pitch = 188; port->hw_streamingparams.linethreshold = 0; - port->hw_streamingparams.pagetablelistvirt = 0; - port->hw_streamingparams.pagetablelistphys = 0; + port->hw_streamingparams.pagetablelistvirt = NULL; + port->hw_streamingparams.pagetablelistphys = NULL; port->hw_streamingparams.numpagetables = 2 + ((SAA7164_TS_NUMBER_OF_LINES * 188) / PAGE_SIZE); |