Commit 9143a437 authored by Oliver Endriss's avatar Oliver Endriss Committed by Mauro Carvalho Chehab
Browse files

[media] ngene: Codingstyle fixes



Codingstyle fixes

Signed-off-by: default avatarOliver Endriss <o.endriss@gmx.de>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 9ca9efb0
Loading
Loading
Loading
Loading
+15 −21
Original line number Diff line number Diff line
@@ -40,6 +40,7 @@
#include "lnbh24.h"
#include "lgdt330x.h"
#include "mt2131.h"
#include "tda18271c2dd.h"
#include "drxk.h"


@@ -99,9 +100,6 @@ static int drxk_gate_ctrl(struct dvb_frontend *fe, int enable)
	return status;
}

struct dvb_frontend *tda18271c2dd_attach(struct dvb_frontend *fe,
					 struct i2c_adapter *i2c, u8 adr);

static int tuner_attach_tda18271(struct ngene_channel *chan)
{
	struct i2c_adapter *i2c;
@@ -114,7 +112,7 @@ static int tuner_attach_tda18271(struct ngene_channel *chan)
	if (chan->fe->ops.i2c_gate_ctrl)
		chan->fe->ops.i2c_gate_ctrl(chan->fe, 0);
	if (!fe) {
		printk("No TDA18271 found!\n");
		printk(KERN_ERR "No TDA18271 found!\n");
		return -ENODEV;
	}

@@ -209,25 +207,22 @@ static int port_has_drxk(struct i2c_adapter *i2c, int port)

	if (i2c_read(i2c, 0x29+port, &val) < 0)
		return 0;
	printk("DRXK@%02x\n", 0x29+port);
	return 1;
}

static int demod_attach_drxk(struct ngene_channel *chan,
			     struct i2c_adapter *i2c)
{
	struct dvb_frontend *fe;

	chan->fe = fe = dvb_attach(drxk_attach,
	chan->fe = dvb_attach(drxk_attach,
				   i2c, 0x29 + (chan->number^2),
				   &chan->fe2);
	if (!chan->fe) {
		printk("No DRXK found!\n");
		printk(KERN_ERR "No DRXK found!\n");
		return -ENODEV;
	}
	fe->sec_priv = chan;
	chan->gate_ctrl = fe->ops.i2c_gate_ctrl;
	fe->ops.i2c_gate_ctrl = drxk_gate_ctrl;
	chan->fe->sec_priv = chan;
	chan->gate_ctrl = chan->fe->ops.i2c_gate_ctrl;
	chan->fe->ops.i2c_gate_ctrl = drxk_gate_ctrl;
	return 0;
}

@@ -257,8 +252,7 @@ static int cineS2_probe(struct ngene_channel *chan)
		i2c_msg.addr = fe_conf->address;
		i2c_msg.len = 3;
		buf[0] = 0xf1;
		switch (chan->number)
		{
		switch (chan->number) {
		case 2:
			buf[1] = 0x5c;
			buf[2] = 0xc2;
@@ -279,7 +273,7 @@ static int cineS2_probe(struct ngene_channel *chan)
		chan->demod_type = 1;
		demod_attach_drxk(chan, i2c);
	} else {
		printk("No demod found on chan %d\n", chan->number);
		printk(KERN_ERR "No demod found on chan %d\n", chan->number);
	}
	return 0;
}
+7 −7
Original line number Diff line number Diff line
@@ -41,7 +41,7 @@

#include "ngene.h"

static int one_adapter = 0;
static int one_adapter;
module_param(one_adapter, int, 0444);
MODULE_PARM_DESC(one_adapter, "Use only one adapter.");

@@ -1443,9 +1443,9 @@ static void release_channel(struct ngene_channel *chan)
		chan->ci_dev = NULL;
	}

	if (chan->fe2) {
	if (chan->fe2)
		dvb_unregister_frontend(chan->fe2);
	}

	if (chan->fe) {
		dvb_unregister_frontend(chan->fe);
		dvb_frontend_detach(chan->fe);
+2 −2
Original line number Diff line number Diff line
@@ -133,9 +133,9 @@ void *tsin_exchange(void *priv, void *buf, u32 len, u32 clock, u32 flags)
		}
		return 0;
	}
	if (chan->users > 0) {
	if (chan->users > 0)
		dvb_dmx_swfilter(&chan->demux, buf, len);
	}

	return NULL;
}

+1 −1

File changed.

Contains only whitespace changes.