diff options
author | Stefan Herdler <herdler@nurfuerspam.de> | 2024-04-15 04:24:09 +0200 |
---|---|---|
committer | Hans Verkuil <hverkuil-cisco@xs4all.nl> | 2024-04-16 00:02:53 +0200 |
commit | 22a8f8c216d2f9cd9d4607758bd2a017a4a8dcbf (patch) | |
tree | 415e75045e655c4cdb4d23d9116c44d7feec786e /drivers/media/pci/ttpci | |
parent | 2b8db3ebaf4c9e3d708ca94dc880e751e5b68ad8 (diff) |
media: ttpci: coding style fixes: constant_comparsation
This patch fixes the following checkpatch warnings:
WARNING:CONSTANT_COMPARISON: Comparisons should place the constant on the right side of the test
Signed-off-by: Stefan Herdler <herdler@nurfuerspam.de>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Diffstat (limited to 'drivers/media/pci/ttpci')
-rw-r--r-- | drivers/media/pci/ttpci/budget-av.c | 4 | ||||
-rw-r--r-- | drivers/media/pci/ttpci/budget-core.c | 2 | ||||
-rw-r--r-- | drivers/media/pci/ttpci/budget.c | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/drivers/media/pci/ttpci/budget-av.c b/drivers/media/pci/ttpci/budget-av.c index 9549e385a909..76660d22f114 100644 --- a/drivers/media/pci/ttpci/budget-av.c +++ b/drivers/media/pci/ttpci/budget-av.c @@ -442,7 +442,7 @@ static int saa7113_setinput(struct budget_av *budget_av, int input) { struct budget *budget = &budget_av->budget; - if (1 != budget_av->has_saa7113) + if (budget_av->has_saa7113 != 1) return -ENODEV; if (input == 1) { @@ -1366,7 +1366,7 @@ static int budget_av_detach(struct saa7146_dev *dev) dprintk(2, "dev: %p\n", dev); - if (1 == budget_av->has_saa7113) { + if (budget_av->has_saa7113 == 1) { saa7146_setgpio(dev, 0, SAA7146_GPIO_OUTLO); msleep(200); diff --git a/drivers/media/pci/ttpci/budget-core.c b/drivers/media/pci/ttpci/budget-core.c index dc8b2de30799..101695c71cc4 100644 --- a/drivers/media/pci/ttpci/budget-core.c +++ b/drivers/media/pci/ttpci/budget-core.c @@ -516,7 +516,7 @@ int ttpci_budget_init(struct budget *budget, struct saa7146_dev *dev, ttpci_eeprom_parse_mac(&budget->i2c_adap, budget->dvb_adapter.proposed_mac); budget->grabbing = saa7146_vmalloc_build_pgtable(dev->pci, budget->buffer_size, &budget->pt); - if (NULL == budget->grabbing) { + if (budget->grabbing == NULL) { ret = -ENOMEM; goto err_del_i2c; } diff --git a/drivers/media/pci/ttpci/budget.c b/drivers/media/pci/ttpci/budget.c index 28a479ce0754..36aef9303223 100644 --- a/drivers/media/pci/ttpci/budget.c +++ b/drivers/media/pci/ttpci/budget.c @@ -791,7 +791,7 @@ static int budget_attach(struct saa7146_dev *dev, struct saa7146_pci_extension_d int err; budget = kmalloc(sizeof(struct budget), GFP_KERNEL); - if (NULL == budget) + if (budget == NULL) return -ENOMEM; dprintk(2, "dev:%p, info:%p, budget:%p\n", dev, info, budget); |