@@ -255,7 +255,7 @@ static void request_module_async(struct work_struct *work)
255255 request_module ("cx18-alsa" );
256256
257257 /* Initialize cx18-alsa for this instance of the cx18 device */
258- if (cx18_ext_init != NULL )
258+ if (cx18_ext_init )
259259 cx18_ext_init (dev );
260260}
261261
@@ -291,11 +291,11 @@ int cx18_msleep_timeout(unsigned int msecs, int intr)
291291/* Release ioremapped memory */
292292static void cx18_iounmap (struct cx18 * cx )
293293{
294- if (cx == NULL )
294+ if (! cx )
295295 return ;
296296
297297 /* Release io memory */
298- if (cx -> enc_mem != NULL ) {
298+ if (cx -> enc_mem ) {
299299 CX18_DEBUG_INFO ("releasing enc_mem\n" );
300300 iounmap (cx -> enc_mem );
301301 cx -> enc_mem = NULL ;
@@ -649,15 +649,15 @@ static void cx18_process_options(struct cx18 *cx)
649649 CX18_INFO ("User specified %s card\n" , cx -> card -> name );
650650 else if (cx -> options .cardtype != 0 )
651651 CX18_ERR ("Unknown user specified type, trying to autodetect card\n" );
652- if (cx -> card == NULL ) {
652+ if (! cx -> card ) {
653653 if (cx -> pci_dev -> subsystem_vendor == CX18_PCI_ID_HAUPPAUGE ) {
654654 cx -> card = cx18_get_card (CX18_CARD_HVR_1600_ESMT );
655655 CX18_INFO ("Autodetected Hauppauge card\n" );
656656 }
657657 }
658- if (cx -> card == NULL ) {
658+ if (! cx -> card ) {
659659 for (i = 0 ; (cx -> card = cx18_get_card (i )); i ++ ) {
660- if (cx -> card -> pci_list == NULL )
660+ if (! cx -> card -> pci_list )
661661 continue ;
662662 for (j = 0 ; cx -> card -> pci_list [j ].device ; j ++ ) {
663663 if (cx -> pci_dev -> device !=
@@ -676,7 +676,7 @@ static void cx18_process_options(struct cx18 *cx)
676676 }
677677done :
678678
679- if (cx -> card == NULL ) {
679+ if (! cx -> card ) {
680680 cx -> card = cx18_get_card (CX18_CARD_HVR_1600_ESMT );
681681 CX18_ERR ("Unknown card: vendor/device: [%04x:%04x]\n" ,
682682 cx -> pci_dev -> vendor , cx -> pci_dev -> device );
@@ -698,7 +698,7 @@ static int cx18_create_in_workq(struct cx18 *cx)
698698 snprintf (cx -> in_workq_name , sizeof (cx -> in_workq_name ), "%s-in" ,
699699 cx -> v4l2_dev .name );
700700 cx -> in_work_queue = alloc_ordered_workqueue ("%s" , 0 , cx -> in_workq_name );
701- if (cx -> in_work_queue == NULL ) {
701+ if (! cx -> in_work_queue ) {
702702 CX18_ERR ("Unable to create incoming mailbox handler thread\n" );
703703 return - ENOMEM ;
704704 }
@@ -1254,7 +1254,7 @@ static void cx18_cancel_out_work_orders(struct cx18 *cx)
12541254{
12551255 int i ;
12561256 for (i = 0 ; i < CX18_MAX_STREAMS ; i ++ )
1257- if (& cx -> streams [i ].video_dev != NULL )
1257+ if (& cx -> streams [i ].video_dev )
12581258 cancel_work_sync (& cx -> streams [i ].out_work_order );
12591259}
12601260
@@ -1299,7 +1299,7 @@ static void cx18_remove(struct pci_dev *pci_dev)
12991299
13001300 pci_disable_device (cx -> pci_dev );
13011301
1302- if (cx -> vbi .sliced_mpeg_data [0 ] != NULL )
1302+ if (cx -> vbi .sliced_mpeg_data [0 ])
13031303 for (i = 0 ; i < CX18_VBI_FRAMES ; i ++ )
13041304 kfree (cx -> vbi .sliced_mpeg_data [i ]);
13051305
0 commit comments