media: ddbridge: split code into multiple files
authorDaniel Scheller <d.scheller@gmx.net>
Sat, 29 Jul 2017 11:28:36 +0000 (07:28 -0400)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Wed, 9 Aug 2017 16:17:01 +0000 (12:17 -0400)
commita96e5ab8a713e99b5d4a4b9110d7226f8dbc97ea
tree12ffe7a45c629cb0502d186cbac4a218a5887fa0
parent335bb883af31baa56be0f5f5630ac50310d222cd
media: ddbridge: split code into multiple files

As of 0.9.9b, the ddbridge code has been split from one single file
(ddbridge-core.c) into multiple files, with the purpose of taking care of
different topics, and to be able to reuse code in different kernel modules
(ddbridge.ko and octonet.ko). This applies the same code split, with a
notable difference:

In the vendor package, the split was done by moving all code parts into
separate files, and in the "main" code files (ddbridge.c and octonet.c),
a simple "#include ddbridge-core.c" was done.

In this patch, the same split (codewise) is done, but all resulting .c/.o
files will be handled by the makefile, with proper prototyping of all
shared functions done in ddbridge.h. To avoid conflicts wrt the global
space, the I2C functions and necessary prototypes for ddbridge-i2c.c are
moved into ddbridge-i2c.h, which is to be included wherever required.

Signed-off-by: Daniel Scheller <d.scheller@gmx.net>
Tested-by: Richard Scobie <r.scobie@clear.net.nz>
Tested-by: Jasmin Jessich <jasmin@anw.at>
Tested-by: Dietmar Spingler <d_spingler@freenet.de>
Tested-by: Manfred Knick <Manfred.Knick@t-online.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
drivers/media/pci/ddbridge/Makefile
drivers/media/pci/ddbridge/ddbridge-core.c
drivers/media/pci/ddbridge/ddbridge-i2c.c [new file with mode: 0644]
drivers/media/pci/ddbridge/ddbridge-i2c.h [new file with mode: 0644]
drivers/media/pci/ddbridge/ddbridge-main.c [new file with mode: 0644]
drivers/media/pci/ddbridge/ddbridge.h