Moderator Control Panel ]

Build failures on Raspberry Pi 3 / OSMC

It's important to keep your driver and software updated.

Build failures on Raspberry Pi 3 / OSMC

Postby hatlessEric » Tue Nov 22, 2016 2:17 am

I am attempting to build the linux drivers for a Raspberrry Pi 3 with osmc installed, for a TBS5280 DVB-T2/T Freeview HD Dual Tuner USB TV.
The driver source has been taken from https://github.com/tbsdtv/media_build.git
uname -r => 4.4.27-2-osmc

The build fails in media_build/v4l/si2168.c with errors:

tbsdriver/media_build/v4l/si2168.c: In function 'si2168_select':
tbsdriver/media_build/v4l/si2168.c:670:9: error: implicit declaration of function 'i2c_mux_priv' [-Werror=implicit-function-declaration]
struct i2c_client *client = i2c_mux_priv(muxc);
^
tbsdriver/media_build/v4l/si2168.c:670:30: warning: initialization makes pointer from integer without a cast
struct i2c_client *client = i2c_mux_priv(muxc);
^
tbsdriver/media_build/v4l/si2168.c: In function 'si2168_deselect':
tbsdriver/media_build/v4l/si2168.c:690:30: warning: initialization makes pointer from integer without a cast
struct i2c_client *client = i2c_mux_priv(muxc);
^
tbsdriver/media_build/v4l/si2168.c: In function 'si2168_probe':
tbsdriver/media_build/v4l/si2168.c:817:2: error: implicit declaration of function 'i2c_mux_alloc' [-Werror=implicit-function-declaration]
dev->muxc = i2c_mux_alloc(client->adapter, &client->dev,
^
tbsdriver/media_build/v4l/si2168.c:818:13: error: 'I2C_MUX_LOCKED' undeclared (first use in this function)
1, 0, I2C_MUX_LOCKED,
^
tbsdriver/media_build/v4l/si2168.c:818:13: note: each undeclared identifier is reported only once for each function it appears in
tbsdriver/media_build/v4l/si2168.c:824:11: error: dereferencing pointer to incomplete type
dev->muxc->priv = client;
^
tbsdriver/media_build/v4l/si2168.c:825:2: error: implicit declaration of function 'i2c_mux_add_adapter' [-Werror=implicit-function-declaration]
ret = i2c_mux_add_adapter(dev->muxc, 0, 0, 0);
^
tbsdriver/media_build/v4l/si2168.c:832:34: error: dereferencing pointer to incomplete type
*config->i2c_adapter = dev->muxc->adapter[0];
^
tbsdriver/media_build/v4l/si2168.c: In function 'si2168_remove':
tbsdriver/media_build/v4l/si2168.c:866:2: error: implicit declaration of function 'i2c_mux_del_adapters' [-Werror=implicit-function-declaration]
i2c_mux_del_adapters(dev->muxc);
^

Looking in si2183.c, I find these calls are wrapped in #defines

#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 7, 0)

and I had hoped I could insert these #defines and the appropriate code into si2168.c, however it is not that simple a diff (the block at si2183.c:1458 does not have an exact analogue in si2168.c)

Can anyone help with backporting this code to a 4.4 kernel ?
It also occurred to me that si2168 may not be required for the TBS5280 DVB-T2/T. Is there a method to just build the drivers for this ?

Thanks
hatlessEric
 
Posts: 2
Joined: Sat Oct 29, 2016 11:26 pm

Re: Build failures on Raspberry Pi 3 / OSMC

Postby crazycat » Wed Nov 23, 2016 2:52 am

Look like backport patches incorrectly applied to si2168 driver.
4.4 kernel 100% supported.
crazycat
 
Posts: 463
Joined: Mon Jan 31, 2011 2:46 am
Location: Ukraine, Kharkov

Re: Build failures on Raspberry Pi 3 / OSMC

Postby hatlessEric » Wed Nov 23, 2016 8:08 am

Mea culpa.
I had commented out the line

$(MAKE) -C ../linux apply_patches

in the v4l/Makefile

(it does report a lot of errors - but I think the real error when I did that was that I didn't have the kernel headers properly configured).
Built installed and appearing in tvheadend.

Thanks for your help.

hE
hatlessEric
 
Posts: 2
Joined: Sat Oct 29, 2016 11:26 pm


Return to Driver & Software Update

Who is online

Users browsing this forum: No registered users and 3 guests