summaryrefslogtreecommitdiffstats
path: root/drivers/media/usb/tm6000
diff options
context:
space:
mode:
authorJulia Lawall <Julia.Lawall@inria.fr>2020-07-26 12:58:30 +0200
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>2020-09-01 13:37:53 +0200
commita357a7840702d24a7d55d0f950af35b1be1ee005 (patch)
tree80ae15dbb023f80eee0a1d0a30b5a5ecb11dcdfd /drivers/media/usb/tm6000
parenta50732124bd922949a1224ee7ca620d91fd182f6 (diff)
downloadlinux-a357a7840702d24a7d55d0f950af35b1be1ee005.tar.bz2
saa7134: drop unnecessary list_empty
list_for_each_safe is able to handle an empty list. The only effect of avoiding the loop is not initializing the index variable. Drop list_empty tests in cases where these variables are not used. The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) <smpl> @@ expression x,e; iterator name list_for_each_safe; statement S; identifier i,j; @@ -if (!(list_empty(x))) { list_for_each_safe(i,j,x) S - } ... when != i when != j ( i = e; | ? j = e; ) </smpl> Signed-off-by: Julia Lawall <Julia.Lawall@inria.fr> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers/media/usb/tm6000')
0 files changed, 0 insertions, 0 deletions