Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5becbc58 authored by Hans Verkuil's avatar Hans Verkuil Committed by Mauro Carvalho Chehab
Browse files

[media] v4l/dvb: fix compiler warnings



media_build/v4l/drxk_hard.c: In function 'DownloadMicrocode':
media_build/v4l/drxk_hard.c:1388:6: warning: variable 'BlockCRC' set but not used [-Wunused-but-set-variable]
media_build/v4l/drxk_hard.c:1384:6: warning: variable 'Drain' set but not used [-Wunused-but-set-variable]
media_build/v4l/drxk_hard.c:1383:6: warning: variable 'Flags' set but not used [-Wunused-but-set-variable]
media_build/v4l/lmedm04.c: In function 'lme2510_probe':
media_build/v4l/lmedm04.c:1208:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable]
media_build/v4l/hopper_cards.c: In function 'hopper_irq_handler':
media_build/v4l/hopper_cards.c:68:26: warning: variable 'lstat' set but not used [-Wunused-but-set-variable]
media_build/v4l/mantis_cards.c: In function 'mantis_irq_handler':
media_build/v4l/mantis_cards.c:76:26: warning: variable 'lstat' set but not used [-Wunused-but-set-variable]
media_build/v4l/mantis_dma.c: In function 'mantis_dma_stop':
media_build/v4l/mantis_dma.c:202:16: warning: variable 'mask' set but not used [-Wunused-but-set-variable]
media_build/v4l/mantis_dma.c:202:6: warning: variable 'stat' set but not used [-Wunused-but-set-variable]
media_build/v4l/mantis_evm.c: In function 'mantis_hifevm_work':
media_build/v4l/mantis_evm.c:44:17: warning: variable 'gpif_mask' set but not used [-Wunused-but-set-variable]
media_build/v4l/stb0899_drv.c: In function 'stb0899_init_calc':
media_build/v4l/stb0899_drv.c:640:5: warning: variable 'agc1cn' set but not used [-Wunused-but-set-variable]
media_build/v4l/stb0899_drv.c: In function 'stb0899_diseqc_init':
media_build/v4l/stb0899_drv.c:830:13: warning: variable 'f22_rx' set but not used [-Wunused-but-set-variable]
media_build/v4l/stb0899_drv.c:826:31: warning: variable 'tx_data' set but not used [-Wunused-but-set-variable]
media_build/v4l/stv0900_sw.c: In function 'stv0900_track_optimization':
media_build/v4l/stv0900_sw.c:838:26: warning: variable 'rolloff' set but not used [-Wunused-but-set-variable]
media_build/v4l/ir-sanyo-decoder.c: In function 'ir_sanyo_decode':
media_build/v4l/ir-sanyo-decoder.c:59:14: warning: variable 'not_address' set but not used [-Wunused-but-set-variable]
media_build/v4l/mceusb.c: In function 'mceusb_dev_printdata':
media_build/v4l/mceusb.c:523:46: warning: variable 'data5' set but not used [-Wunused-but-set-variable]

Signed-off-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent fdf07b02
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -1205,14 +1205,13 @@ static int lme2510_probe(struct usb_interface *intf,
		const struct usb_device_id *id)
{
	struct usb_device *udev = interface_to_usbdev(intf);
	int ret = 0;

	usb_reset_configuration(udev);

	usb_set_interface(udev, intf->cur_altsetting->desc.bInterfaceNumber, 1);

	if (udev->speed != USB_SPEED_HIGH) {
		ret = usb_reset_device(udev);
		usb_reset_device(udev);
		info("DEV Failed to connect in HIGH SPEED mode");
		return -ENODEV;
	}
+10 −4
Original line number Diff line number Diff line
@@ -1380,20 +1380,20 @@ static int DownloadMicrocode(struct drxk_state *state,
			     const u8 pMCImage[], u32 Length)
{
	const u8 *pSrc = pMCImage;
	u16 Flags;
	u16 Drain;
	u32 Address;
	u16 nBlocks;
	u16 BlockSize;
	u16 BlockCRC;
	u32 offset = 0;
	u32 i;
	int status = 0;

	dprintk(1, "\n");

	/* down the drain (we don care about MAGIC_WORD) */
	/* down the drain (we don't care about MAGIC_WORD) */
#if 0
	/* For future reference */
	Drain = (pSrc[0] << 8) | pSrc[1];
#endif
	pSrc += sizeof(u16);
	offset += sizeof(u16);
	nBlocks = (pSrc[0] << 8) | pSrc[1];
@@ -1410,11 +1410,17 @@ static int DownloadMicrocode(struct drxk_state *state,
		pSrc += sizeof(u16);
		offset += sizeof(u16);

#if 0
		/* For future reference */
		Flags = (pSrc[0] << 8) | pSrc[1];
#endif
		pSrc += sizeof(u16);
		offset += sizeof(u16);

#if 0
		/* For future reference */
		BlockCRC = (pSrc[0] << 8) | pSrc[1];
#endif
		pSrc += sizeof(u16);
		offset += sizeof(u16);

+1 −7
Original line number Diff line number Diff line
@@ -637,11 +637,9 @@ static void stb0899_init_calc(struct stb0899_state *state)
	struct stb0899_internal *internal = &state->internal;
	int master_clk;
	u8 agc[2];
	u8 agc1cn;
	u32 reg;

	/* Read registers (in burst mode)	*/
	agc1cn = stb0899_read_reg(state, STB0899_AGC1CN);
	stb0899_read_regs(state, STB0899_AGC1REF, agc, 2); /* AGC1R and AGC2O	*/

	/* Initial calculations	*/
@@ -823,15 +821,12 @@ static int stb0899_send_diseqc_burst(struct dvb_frontend *fe, fe_sec_mini_cmd_t

static int stb0899_diseqc_init(struct stb0899_state *state)
{
	struct dvb_diseqc_master_cmd tx_data;
/*
	struct dvb_diseqc_slave_reply rx_data;
*/
	u8 f22_tx, f22_rx, reg;
	u8 f22_tx, reg;

	u32 mclk, tx_freq = 22000;/* count = 0, i; */
	tx_data.msg[0] = 0xe2;
	tx_data.msg_len = 3;
	reg = stb0899_read_reg(state, STB0899_DISCNTRL2);
	STB0899_SETFIELD_VAL(ONECHIP_TRX, reg, 0);
	stb0899_write_reg(state, STB0899_DISCNTRL2, reg);
@@ -849,7 +844,6 @@ static int stb0899_diseqc_init(struct stb0899_state *state)
	f22_tx = mclk / (tx_freq * 32);
	stb0899_write_reg(state, STB0899_DISF22, f22_tx); /* DiSEqC Tx freq	*/
	state->rx_freq = 20000;
	f22_rx = mclk / (state->rx_freq * 32);

	return 0;
}
+0 −2
Original line number Diff line number Diff line
@@ -835,7 +835,6 @@ static void stv0900_track_optimization(struct dvb_frontend *fe)
		blind_tun_sw = 0,
		modulation;

	enum fe_stv0900_rolloff rolloff;
	enum fe_stv0900_modcode foundModcod;

	dprintk("%s\n", __func__);
@@ -940,7 +939,6 @@ static void stv0900_track_optimization(struct dvb_frontend *fe)

	freq1 = stv0900_read_reg(intp, CFR2);
	freq0 = stv0900_read_reg(intp, CFR1);
	rolloff = stv0900_get_bits(intp, ROLLOFF_STATUS);
	if (intp->srch_algo[demod] == STV0900_BLIND_SEARCH) {
		stv0900_write_reg(intp, SFRSTEP, 0x00);
		stv0900_write_bits(intp, SCAN_ENABLE, 0);
+1 −2
Original line number Diff line number Diff line
@@ -65,7 +65,7 @@ static int devs;

static irqreturn_t hopper_irq_handler(int irq, void *dev_id)
{
	u32 stat = 0, mask = 0, lstat = 0;
	u32 stat = 0, mask = 0;
	u32 rst_stat = 0, rst_mask = 0;

	struct mantis_pci *mantis;
@@ -80,7 +80,6 @@ static irqreturn_t hopper_irq_handler(int irq, void *dev_id)

	stat = mmread(MANTIS_INT_STAT);
	mask = mmread(MANTIS_INT_MASK);
	lstat = stat & ~MANTIS_INT_RISCSTAT;
	if (!(stat & mask))
		return IRQ_NONE;

Loading