提交 dcdda65f 编写于 作者: A Andrew de Quincey 提交者: Mauro Carvalho Chehab

V4L/DVB (3741): Budget-core doesn't check if register adapter fails

If you have more than DVB_MAX_ADAPTERS in your machine, this causes an oops.
Signed-off-by: NAndrew de Quincey <adq_dvb@lidskialf.net>
Signed-off-by: NMauro Carvalho Chehab <mchehab@infradead.org>
上级 0dbbc0a7
...@@ -400,7 +400,9 @@ int ttpci_budget_init(struct budget *budget, struct saa7146_dev *dev, ...@@ -400,7 +400,9 @@ int ttpci_budget_init(struct budget *budget, struct saa7146_dev *dev,
budget->dev->name, budget->buffer_width, budget->buffer_height); budget->dev->name, budget->buffer_width, budget->buffer_height);
printk("%s: dma buffer size %u\n", budget->dev->name, budget->buffer_size); printk("%s: dma buffer size %u\n", budget->dev->name, budget->buffer_size);
dvb_register_adapter(&budget->dvb_adapter, budget->card->name, owner); if ((ret = dvb_register_adapter(&budget->dvb_adapter, budget->card->name, owner)) < 0) {
return ret;
}
/* set dd1 stream a & b */ /* set dd1 stream a & b */
saa7146_write(dev, DD1_STREAM_B, 0x00000000); saa7146_write(dev, DD1_STREAM_B, 0x00000000);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册