media: vivid: move the devnode creation logic to a separate function
authorMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Tue, 1 Sep 2020 13:43:45 +0000 (15:43 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Mon, 7 Sep 2020 14:01:57 +0000 (16:01 +0200)
commit62c6b4c9e3c8e30ba4ad6c85732f00a26c5e4394
tree5128e0007e83ddd997fe3c47b34d57de9967e803
parentfaf21f2867a51866599fa75a9be66dd12bc8db13
media: vivid: move the devnode creation logic to a separate function

In order to reduce even further the size of the big
vivid_create_instance() function, let's place the part of the
logic which creates the device nodes into a separate function.

    With this and the past patches, those warnings finally
    vanishes:

            drivers/media/test-drivers/vivid/vivid-core.c: drivers/media/test-drivers/vivid/vivid-core.c:1189 vivid_create_instance() parse error: turning off implications after 60 seconds
            drivers/media/test-drivers/vivid/vivid-core.c: drivers/media/test-drivers/vivid/vivid-core.c:1257 vivid_create_instance() parse error: __split_smt: function too hairy.  Giving up after 303 seconds

The init code also seems more organized after breaking the long
function into a smaller set.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/test-drivers/vivid/vivid-core.c