lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1600683624-5863-41-git-send-email-clabbe@baylibre.com>
Date:   Mon, 21 Sep 2020 10:20:15 +0000
From:   Corentin Labbe <clabbe@...libre.com>
To:     gregkh@...uxfoundation.org, laurent.pinchart@...net.be,
        mchehab@...nel.org
Cc:     devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org,
        linux-media@...r.kernel.org, Corentin Labbe <clabbe@...libre.com>
Subject: [PATCH RFT/RFC 40/49] staging: media: zoran: device support only 32bit DMA address

The zoran device only supports 32bit DMA address.

Signed-off-by: Corentin Labbe <clabbe@...libre.com>
---
 drivers/staging/media/zoran/zoran_card.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/staging/media/zoran/zoran_card.c b/drivers/staging/media/zoran/zoran_card.c
index 864196e7acae..ab16a70a7451 100644
--- a/drivers/staging/media/zoran/zoran_card.c
+++ b/drivers/staging/media/zoran/zoran_card.c
@@ -1101,6 +1101,12 @@ static int zoran_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
 	int card_num;
 	const char *codec_name, *vfe_name;
 	unsigned int nr;
+	int err;
+
+	err = dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32));
+	if (err)
+		return -ENODEV;
+	vb2_dma_contig_set_max_seg_size(&pdev->dev, DMA_BIT_MASK(32));
 
 	nr = zoran_num++;
 	if (nr >= BUZ_MAX) {
-- 
2.26.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ