2011-07-04 04:23:11 +07:00
|
|
|
/*
|
|
|
|
* ddbridge-regs.h: Digital Devices PCIe bridge driver
|
|
|
|
*
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
* Copyright (C) 2010-2017 Digital Devices GmbH
|
2011-07-04 04:23:11 +07:00
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* version 2 only, as published by the Free Software Foundation.
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
2016-10-28 18:31:20 +07:00
|
|
|
* To obtain the license, point your browser to
|
|
|
|
* http://www.gnu.org/copyleft/gpl.html
|
2011-07-04 04:23:11 +07:00
|
|
|
*/
|
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
/* ------------------------------------------------------------------------- */
|
|
|
|
/* SPI Controller */
|
2011-07-04 04:23:11 +07:00
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
#define SPI_CONTROL 0x10
|
|
|
|
#define SPI_DATA 0x14
|
2011-07-04 04:23:11 +07:00
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
/* ------------------------------------------------------------------------- */
|
|
|
|
/* GPIO */
|
2011-07-04 04:23:11 +07:00
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
#define GPIO_OUTPUT 0x20
|
|
|
|
#define GPIO_INPUT 0x24
|
|
|
|
#define GPIO_DIRECTION 0x28
|
2011-07-04 04:23:11 +07:00
|
|
|
|
2011-07-04 04:24:07 +07:00
|
|
|
/* ------------------------------------------------------------------------- */
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
/* MDIO */
|
2011-07-04 04:23:11 +07:00
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
#define MDIO_CTRL 0x20
|
|
|
|
#define MDIO_ADR 0x24
|
|
|
|
#define MDIO_REG 0x28
|
|
|
|
#define MDIO_VAL 0x2C
|
2011-07-04 04:23:11 +07:00
|
|
|
|
2011-07-04 04:24:07 +07:00
|
|
|
/* ------------------------------------------------------------------------- */
|
2011-07-04 04:23:11 +07:00
|
|
|
|
2017-04-10 02:38:25 +07:00
|
|
|
#define BOARD_CONTROL 0x30
|
|
|
|
|
|
|
|
/* ------------------------------------------------------------------------- */
|
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
/* Interrupt controller
|
|
|
|
* How many MSI's are available depends on HW (Min 2 max 8)
|
|
|
|
* How many are usable also depends on Host platform
|
|
|
|
*/
|
2011-07-04 04:23:11 +07:00
|
|
|
|
|
|
|
#define INTERRUPT_BASE (0x40)
|
|
|
|
|
|
|
|
#define INTERRUPT_ENABLE (INTERRUPT_BASE + 0x00)
|
|
|
|
#define MSI1_ENABLE (INTERRUPT_BASE + 0x04)
|
|
|
|
#define MSI2_ENABLE (INTERRUPT_BASE + 0x08)
|
|
|
|
#define MSI3_ENABLE (INTERRUPT_BASE + 0x0C)
|
|
|
|
#define MSI4_ENABLE (INTERRUPT_BASE + 0x10)
|
|
|
|
#define MSI5_ENABLE (INTERRUPT_BASE + 0x14)
|
|
|
|
#define MSI6_ENABLE (INTERRUPT_BASE + 0x18)
|
|
|
|
#define MSI7_ENABLE (INTERRUPT_BASE + 0x1C)
|
|
|
|
|
|
|
|
#define INTERRUPT_STATUS (INTERRUPT_BASE + 0x20)
|
|
|
|
#define INTERRUPT_ACK (INTERRUPT_BASE + 0x20)
|
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
/* Temperature Monitor ( 2x LM75A @ 0x90,0x92 I2c ) */
|
|
|
|
#define TEMPMON_BASE (0x1c0)
|
|
|
|
#define TEMPMON_CONTROL (TEMPMON_BASE + 0x00)
|
|
|
|
|
|
|
|
#define TEMPMON_CONTROL_AUTOSCAN (0x00000002)
|
|
|
|
#define TEMPMON_CONTROL_INTENABLE (0x00000004)
|
|
|
|
#define TEMPMON_CONTROL_OVERTEMP (0x00008000)
|
|
|
|
|
|
|
|
/* SHORT Temperature in Celsius x 256 */
|
|
|
|
#define TEMPMON_SENSOR0 (TEMPMON_BASE + 0x04)
|
|
|
|
#define TEMPMON_SENSOR1 (TEMPMON_BASE + 0x08)
|
|
|
|
|
|
|
|
#define TEMPMON_FANCONTROL (TEMPMON_BASE + 0x10)
|
2011-07-04 04:23:11 +07:00
|
|
|
|
2011-07-04 04:24:07 +07:00
|
|
|
/* ------------------------------------------------------------------------- */
|
|
|
|
/* I2C Master Controller */
|
2011-07-04 04:23:11 +07:00
|
|
|
|
|
|
|
#define I2C_COMMAND (0x00)
|
|
|
|
#define I2C_TIMING (0x04)
|
2011-07-04 04:24:07 +07:00
|
|
|
#define I2C_TASKLENGTH (0x08) /* High read, low write */
|
|
|
|
#define I2C_TASKADDRESS (0x0C) /* High read, low write */
|
2011-07-04 04:23:11 +07:00
|
|
|
#define I2C_MONITOR (0x1C)
|
|
|
|
|
|
|
|
#define I2C_SPEED_400 (0x04030404)
|
|
|
|
#define I2C_SPEED_100 (0x13121313)
|
|
|
|
|
2011-07-04 04:24:07 +07:00
|
|
|
/* ------------------------------------------------------------------------- */
|
|
|
|
/* DMA Controller */
|
2011-07-04 04:23:11 +07:00
|
|
|
|
|
|
|
#define DMA_BASE_WRITE (0x100)
|
|
|
|
#define DMA_BASE_READ (0x140)
|
|
|
|
|
2017-10-16 03:51:51 +07:00
|
|
|
#define TS_CONTROL(_io) ((_io)->regs + 0x00)
|
|
|
|
#define TS_CONTROL2(_io) ((_io)->regs + 0x04)
|
2011-07-04 04:24:07 +07:00
|
|
|
|
|
|
|
/* ------------------------------------------------------------------------- */
|
|
|
|
/* DMA Buffer */
|
2011-07-04 04:23:11 +07:00
|
|
|
|
2017-10-16 03:51:51 +07:00
|
|
|
#define DMA_BUFFER_CONTROL(_dma) ((_dma)->regs + 0x00)
|
|
|
|
#define DMA_BUFFER_ACK(_dma) ((_dma)->regs + 0x04)
|
|
|
|
#define DMA_BUFFER_CURRENT(_dma) ((_dma)->regs + 0x08)
|
|
|
|
#define DMA_BUFFER_SIZE(_dma) ((_dma)->regs + 0x0c)
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
|
|
|
|
/* ------------------------------------------------------------------------- */
|
|
|
|
/* CI Interface (only CI-Bridge) */
|
|
|
|
|
2017-10-16 03:51:51 +07:00
|
|
|
#define CI_BASE (0x400)
|
|
|
|
#define CI_CONTROL(i) (CI_BASE + (i) * 32 + 0x00)
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
|
2017-10-16 03:51:51 +07:00
|
|
|
#define CI_DO_ATTRIBUTE_RW(i) (CI_BASE + (i) * 32 + 0x04)
|
|
|
|
#define CI_DO_IO_RW(i) (CI_BASE + (i) * 32 + 0x08)
|
|
|
|
#define CI_READDATA(i) (CI_BASE + (i) * 32 + 0x0c)
|
|
|
|
#define CI_DO_READ_ATTRIBUTES(i) (CI_BASE + (i) * 32 + 0x10)
|
2011-07-04 04:23:11 +07:00
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
#define CI_RESET_CAM (0x00000001)
|
|
|
|
#define CI_POWER_ON (0x00000002)
|
|
|
|
#define CI_ENABLE (0x00000004)
|
|
|
|
#define CI_BYPASS_DISABLE (0x00000010)
|
2011-07-04 04:23:11 +07:00
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
#define CI_CAM_READY (0x00010000)
|
|
|
|
#define CI_CAM_DETECT (0x00020000)
|
|
|
|
#define CI_READY (0x80000000)
|
2011-07-04 04:23:11 +07:00
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
#define CI_READ_CMD (0x40000000)
|
|
|
|
#define CI_WRITE_CMD (0x80000000)
|
2011-07-04 04:23:11 +07:00
|
|
|
|
media: ddbridge: bump ddbridge code to version 0.9.29
This huge patch bumps the ddbridge driver to version 0.9.29. Compared to
the vendor driver package, DD OctoNET including GTL link support, and all
DVB-C Modulator card support has been removed since this requires large
changes to the underlying DVB core API, which should eventually be done
separately, and, after that, the functionality/device support can be added
back rather easy.
While the diff is rather large, the bump is mostly a big refactor of all
data structures. Yet, the MSI support (message signaled interrupts) is
greatly improved, also all currently available CI single/duo bridge cards
are fully supported.
More changes compared to the upstream driver:
- the DDB_USE_WORKER flag/define was removed, kernel worker functionality
will be used.
- coding style is properly fixed (zero complaints from checkpatch)
- all (not much though) CamelCase has been fixed to kernel_case
- (private) IOCTLs temporarily removed (which are mainly used to provide
rarely-used FPGA update functionality)
Great care has been taken to keep all previous changes and fixes (e.g.
kernel logging via dev_*(), pointer annotations and such) intact.
Permission to reuse and mainline the driver code was formally granted by
Ralph Metzler <rjkm@metzlerbros.de>.
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>
2017-08-12 18:55:52 +07:00
|
|
|
#define CI_BUFFER_BASE (0x3000)
|
|
|
|
#define CI_BUFFER_SIZE (0x0800)
|
2011-07-04 04:23:11 +07:00
|
|
|
|
2017-10-16 03:51:51 +07:00
|
|
|
#define CI_BUFFER(i) (CI_BUFFER_BASE + (i) * CI_BUFFER_SIZE)
|
2017-07-10 02:42:44 +07:00
|
|
|
|
|
|
|
/* ------------------------------------------------------------------------- */
|
|
|
|
/* LNB commands (mxl5xx / Max S8) */
|
|
|
|
|
|
|
|
#define LNB_BASE (0x400)
|
|
|
|
#define LNB_CONTROL(i) (LNB_BASE + (i) * 0x20 + 0x00)
|
|
|
|
|
2017-10-16 03:51:51 +07:00
|
|
|
#define LNB_CMD (7ULL << 0)
|
2017-07-10 02:42:44 +07:00
|
|
|
#define LNB_CMD_NOP 0
|
|
|
|
#define LNB_CMD_INIT 1
|
|
|
|
#define LNB_CMD_LOW 3
|
|
|
|
#define LNB_CMD_HIGH 4
|
|
|
|
#define LNB_CMD_OFF 5
|
|
|
|
#define LNB_CMD_DISEQC 6
|
|
|
|
|
2017-10-16 03:51:51 +07:00
|
|
|
#define LNB_BUSY BIT_ULL(4)
|
|
|
|
#define LNB_TONE BIT_ULL(15)
|
2017-07-10 02:42:44 +07:00
|
|
|
|
|
|
|
#define LNB_BUF_LEVEL(i) (LNB_BASE + (i) * 0x20 + 0x10)
|
|
|
|
#define LNB_BUF_WRITE(i) (LNB_BASE + (i) * 0x20 + 0x14)
|
|
|
|
|