media: ite-cir: probe of ITE8708 on ASUS PN50 fails
authorSean Young <sean@mess.org>
Thu, 8 Apr 2021 08:33:22 +0000 (10:33 +0200)
committerMauro Carvalho Chehab <mchehab+huawei@kernel.org>
Fri, 9 Apr 2021 11:04:25 +0000 (13:04 +0200)
The Asus PN50 has 16 byte io region for the ITE8708 in its DSDT, which
causes the probe fail. So, accept larger regions.

Link: https://www.spinics.net/lists/linux-media/msg177725.html
Cc: Nikolaos Beredimas <beredim@gmail.com>
Reported-by: Michael Zimmermann <sigmaepsilon92@gmail.com>
Signed-off-by: Sean Young <sean@mess.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
drivers/media/rc/ite-cir.c

index 9388774..5bc23e8 100644 (file)
@@ -1333,7 +1333,7 @@ static int ite_probe(struct pnp_dev *pdev, const struct pnp_device_id
 
        /* validate pnp resources */
        if (!pnp_port_valid(pdev, io_rsrc_no) ||
-           pnp_port_len(pdev, io_rsrc_no) != dev_desc->io_region_size) {
+           pnp_port_len(pdev, io_rsrc_no) < dev_desc->io_region_size) {
                dev_err(&pdev->dev, "IR PNP Port not valid!\n");
                goto exit_free_dev_rdev;
        }