/****************************************************************************/
-DEFINE_MUTEX(redirect_lock);
+static DEFINE_MUTEX(redirect_lock);
struct workqueue_struct *ddb_wq;
static int ddb_unredirect(struct ddb_port *port)
{
- struct ddb_input *oredi, *iredi = 0;
- struct ddb_output *iredo = 0;
+ struct ddb_input *oredi, *iredi = NULL;
+ struct ddb_output *iredo = NULL;
/* dev_info(port->dev->dev,
* "unredirect %d.%d\n", port->dev->nr, port->nr);
ddb_redirect_dma(oredi->port->dev,
oredi->dma, iredo->dma);
}
- port->input[0]->redo = 0;
+ port->input[0]->redo = NULL;
ddb_set_dma_table(port->input[0]);
}
oredi->redi = iredi;
- port->input[0]->redi = 0;
+ port->input[0]->redi = NULL;
}
- oredi->redo = 0;
- port->output->redi = 0;
+ oredi->redo = NULL;
+ port->output->redi = NULL;
ddb_set_dma_table(oredi);
done:
if (input2) {
if (input->redi) {
input2->redi = input->redi;
- input->redi = 0;
+ input->redi = NULL;
} else
input2->redi = input;
}
.open = ts_open,
.release = ts_release,
.poll = ts_poll,
- .mmap = 0,
+ .mmap = NULL,
};
static struct dvb_device dvbdev_ci = {
- .priv = 0,
+ .priv = NULL,
.readers = 1,
.writers = 1,
.users = 2,
static void ci_attach(struct ddb_port *port)
{
- struct ddb_ci *ci = 0;
+ struct ddb_ci *ci = NULL;
ci = kzalloc(sizeof(*ci), GFP_KERNEL);
if (!ci)
/****************************************************************************/
/****************************************************************************/
-struct cxd2099_cfg cxd_cfg = {
+static struct cxd2099_cfg cxd_cfg = {
.bitrate = 72000,
.adr = 0x40,
.polarity = 1,
if (res) {
ddb_device_attrs_del(dev);
device_destroy(&ddb_class, MKDEV(ddb_major, dev->nr));
- ddbs[dev->nr] = 0;
+ ddbs[dev->nr] = NULL;
dev->ddb_dev = ERR_PTR(-ENODEV);
} else
ddb_num++;
static inline u32 ddblreadl(struct ddb_link *link, u32 adr)
{
- return readl((char *) (link->dev->regs + (adr)));
+ return readl(link->dev->regs + adr);
}
static inline void ddblwritel(struct ddb_link *link, u32 val, u32 adr)
{
- writel(val, (char *) (link->dev->regs + (adr)));
+ writel(val, link->dev->regs + adr);
}
static inline u32 ddbreadl(struct ddb *dev, u32 adr)
{
- return readl((char *) (dev->regs + (adr)));
+ return readl(dev->regs + adr);
}
static inline void ddbwritel(struct ddb *dev, u32 val, u32 adr)
{
- writel(val, (char *) (dev->regs + (adr)));
+ writel(val, dev->regs + adr);
}
static inline void ddbcpyto(struct ddb *dev, u32 adr, void *src, long count)
{
- return memcpy_toio((char *) (dev->regs + adr), src, count);
+ return memcpy_toio(dev->regs + adr, src, count);
}
static inline void ddbcpyfrom(struct ddb *dev, void *dst, u32 adr, long count)
{
- return memcpy_fromio(dst, (char *) (dev->regs + adr), count);
+ return memcpy_fromio(dst, dev->regs + adr, count);
}
static inline u32 safe_ddbreadl(struct ddb *dev, u32 adr)