提交 a4df8e1d 编写于 作者: A Alan McIvor 提交者: Mauro Carvalho Chehab

V4L/DVB (7394): saa7134: add number of devices check

This patch fixes reported problems when trying to add a 9th device into a
system.
Signed-off-by: NAlan McIvor <alan.mcivor@reveal.co.nz>
Signed-off-by: NHartmut Hackmann <hartmut.hackmann@t-online.de>
Signed-off-by: NMauro Carvalho Chehab <mchehab@infradead.org>
上级 7bff4b4d
......@@ -866,6 +866,9 @@ static int __devinit saa7134_initdev(struct pci_dev *pci_dev,
int err;
int mask;
if (saa7134_devcount == SAA7134_MAXBOARDS)
return -ENOMEM;
dev = kzalloc(sizeof(*dev),GFP_KERNEL);
if (NULL == dev)
return -ENOMEM;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册