Message ID | vtdwvjmd6mo7ln6oxtmjro7vizngwykeoaru272rbrontxedyj@6hmjcyrfwdvv (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <intel-gfx-bounces@lists.freedesktop.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6AF21D6EBEE for <intel-gfx@archiver.kernel.org>; Fri, 29 Nov 2024 09:16:16 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id C230010E4A2; Fri, 29 Nov 2024 09:16:15 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="aIwBFcEd"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.9]) by gabe.freedesktop.org (Postfix) with ESMTPS id 71F6810E4A2 for <intel-gfx@lists.freedesktop.org>; Fri, 29 Nov 2024 09:16:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1732871774; x=1764407774; h=date:from:to:cc:subject:message-id:mime-version; bh=P7NeDjCRks1p9Wuk8P7MtYKA0aQnbd1yoCu1hY3F9+8=; b=aIwBFcEd/ceNz6WfjijdxXrCZ05MrMvb968QXqbDcsa/xuomsOI4LJds gp+mVmk8LzPSxfUwUD/x3AJnqwoNF0hH52kiuAhJgCq7GpsLjSnb628Va BU1wITXKFhPhFZ1Dqr33081qF+6fZ1ps4LL8g+hNHG6fBecACmJyRTgd2 M+BZupo5DJiRN8D1HxTfm84ig5iq8DWHGA5HkoIzcPoeifZREo95fBOYB BrbIDuro/Oh6rwOoEDig4ldjHtf9hGvqYQvy6x4BwaB+P9KhBQ1W1aNw4 bpeLlPpuoRMkJiYirz5PrZkHE+NI0R63j6YpURl6wr0mIZM729wuf9wqc Q==; X-CSE-ConnectionGUID: UiStLogbQ++kH6tiEt9R2g== X-CSE-MsgGUID: tqpQEEwsRn+3dz+CdU7lag== X-IronPort-AV: E=McAfee;i="6700,10204,11270"; a="43773498" X-IronPort-AV: E=Sophos;i="6.12,195,1728975600"; d="scan'208";a="43773498" Received: from orviesa001.jf.intel.com ([10.64.159.141]) by fmvoesa103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Nov 2024 01:16:14 -0800 X-CSE-ConnectionGUID: bYyGuSv6Qi+GqDN2VHni/Q== X-CSE-MsgGUID: ciDWldukSJ+GpbDuQnAR0g== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.12,195,1728975600"; d="scan'208";a="129928590" Received: from fmsmsx601.amr.corp.intel.com ([10.18.126.81]) by orviesa001.jf.intel.com with ESMTP/TLS/AES256-GCM-SHA384; 29 Nov 2024 01:16:14 -0800 Received: from fmsmsx603.amr.corp.intel.com (10.18.126.83) by fmsmsx601.amr.corp.intel.com (10.18.126.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Fri, 29 Nov 2024 01:16:13 -0800 Received: from FMSEDG603.ED.cps.intel.com (10.1.192.133) by fmsmsx603.amr.corp.intel.com (10.18.126.83) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39 via Frontend Transport; Fri, 29 Nov 2024 01:16:13 -0800 Received: from NAM12-BN8-obe.outbound.protection.outlook.com (104.47.55.170) by edgegateway.intel.com (192.55.55.68) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Fri, 29 Nov 2024 01:16:13 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=P7nnRQZNRgYJonafCloMaf364DEYWBxF0tP1PaepE8pBqOp3JyjoyAavQ4EZV8nVhWAqHEp6Kly3g6dUz2iXV2n5efq6nDfXpVyOS2u0YWd0A5JCKiXNGAHjyB6ke3RDHJKHz43BrkvAV+mJcAZHTZIXyOIDRuEbB1Ew8CKb3/0wh3Slb2ghd4bA3azr1au14b+bIpO0wtKGOetf7RcCvrGmgfxT0aBqfmJj20svImgW1pFKR1N3QvtlHk27eE3rE3eitaKYYX3MNDUY7vWMfHjQs4bo/VOAfOxY9Gdsver9l/GQfhSn8qf/90fc0hnEEK35eUceJhLq9+/HCRMz+Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=fXxGEvmgtISJKNuGVOOjAKlO3NulIfMw2hULu3FzLRw=; b=PjW4jGFv9OKpZz2KmSFY3fbkcXxKk7RKJIf7jwe1wij3AF33amvK3cgWJqOLrl9PvfdrhDOHK4NTPt37OVGDmIMiAJnMaO1PgnGHazljfOMus6EQPADmUAxHkUYUI+ONyoZauPOvVpNMccgDj5TfUDpXTe99Rnk38N2LnbCUrS8dpqFJmdVRKY3NaMPRtJSLHzispDn2NvRrwXTNetI0lgNRdjFfQBGRF2sM9ndGMosDPbOFh9YeGbxBKFfGOFRGMnMfQIZm+Q7TXEIrsVEJI+Ir8osoR1jLtLzcDefqK38unQlsZJs3t7UqQDGHIHW5zU65mDwEFDlAtnTCzLQYWg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; Received: from CO1PR11MB5057.namprd11.prod.outlook.com (2603:10b6:303:6c::15) by PH7PR11MB6498.namprd11.prod.outlook.com (2603:10b6:510:1f1::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8207.13; Fri, 29 Nov 2024 09:16:10 +0000 Received: from CO1PR11MB5057.namprd11.prod.outlook.com ([fe80::4610:6d6c:9af6:2548]) by CO1PR11MB5057.namprd11.prod.outlook.com ([fe80::4610:6d6c:9af6:2548%7]) with mapi id 15.20.8207.014; Fri, 29 Nov 2024 09:16:10 +0000 Date: Fri, 29 Nov 2024 09:16:01 +0000 From: Krzysztof Karas <krzysztof.karas@intel.com> To: <intel-gfx@lists.freedesktop.org> CC: <andi.shyti@linux.intel.com>, <chris@chris-wilson.co.uk> Subject: [PATCH RESEND] drm/i915: add GEM_WARN_ON to remap_io_sg Message-ID: <vtdwvjmd6mo7ln6oxtmjro7vizngwykeoaru272rbrontxedyj@6hmjcyrfwdvv> "Organization: Intel Technology Poland sp. z o.o. - ul. Slowackiego 173, 80-298 Gdansk - KRS 101882 - NIP 957-07-52-316" Content-Type: text/plain; charset="utf-8" Content-Disposition: inline X-ClientProxiedBy: FR2P281CA0143.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:98::16) To CO1PR11MB5057.namprd11.prod.outlook.com (2603:10b6:303:6c::15) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CO1PR11MB5057:EE_|PH7PR11MB6498:EE_ X-MS-Office365-Filtering-Correlation-Id: 3fce9f2e-aa0f-413d-23b7-08dd105676bf X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|1800799024|366016; X-Microsoft-Antispam-Message-Info: =?utf-8?q?8ZtNt89W56IHDdmLF8q7w1EglVGfEH6?= =?utf-8?q?Tdon46UDA71pAvd7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RhZ4ITZ75yCcR8WZxs6gLyI7KOTbE1fmjoHJXxJvVj1J5V?= =?utf-8?q?6aH6IMitBn19qRu3Zb5UM2CCe3qEWO1CDTBwQwQ7dqMemQIzVR2rBjg+TBtFKbupN?= =?utf-8?q?rC77QkSReuLRbYP6hpjBiTPJGyLoWN8InSe/zGdtpBeS0yJJNJJ6H006magMl3N7E?= =?utf-8?q?syqCB7RPduICKrOmiM/Rtu+Cvba2AXcWD/60ur5XdL+zjJDYh4fdSDqjudcTBSkxX?= =?utf-8?q?ES/G1soc1KIDq/yWzVhGavAcRz6t3DZ9poMBQzkw/BkvzDLSK29pGl9rDt9vwSkHn?= =?utf-8?q?I2PBe2/oRng4ztcWfjGNXTj/Ce2CCCt6TAvY5VaiurKqfhdbhckWBlKO/f3hKgQtW?= =?utf-8?q?qYzjdam+43UjyiDblnSwX9SRAdf7xQfgAHQ=3D=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:CO1PR11MB5057.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(376014)(1800799024)(366016); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?ANtV0rq8onqg0FxTQuGg14li0/qv?= =?utf-8?q?HvDG9lhdNhCSEc3eyuzZzNX+BhGJJlcFsTvRWPxYoh3MMHobtO8b6PCWjIiYcRSXQ?= =?utf-8?q?bp7JjSNREAkXqw3xzNDJHNXaFtzr4tUMYU4bB3NUBz5j8r7R/ZLbTQLJ8cdM4A4dC?= =?utf-8?q?5OyrJmvoR4Jz8t6Teur0Nnu4ychj7Kt8bQFt+5KSoFHrAmR1uTTGTU+kLwxpRt6ux?= =?utf-8?q?sLWd+iqemSbAHr2+yO04qgM51lFyTUCXyxTwBxIfBuLrkwNlYPNPQiZ8gpilTb8N8?= =?utf-8?q?FAsIWvG5qXfcY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cAp7lX0hwmJlhgaFT75VfLu6CDPsl5+0xbHajepXhmcOJm/+Oaj?= =?utf-8?q?nODP6ofdaa9FOA7kbzadVEXNJnZR0fKpm36sPuqAEDf+h0nMs8S657XN96sVAXJDr?= =?utf-8?q?CL7w0sPRms2mKeAk1kJjY2zNH8UP9TXBbj+oJ4uO8y7h//I28fPLEFk9N7AXFJGo5?= =?utf-8?q?BNH/bm4p19ZHP49vFgi0JfwqpnV6dJy0RIIkfiOeBKBAZyuJ4UHrhiWyLUi/MSMdH?= =?utf-8?q?PRhzP9l0W8oF0F2/B0aNSP3ufiFRFyWELRwexqYKZ0mi9m4cUsxYlk3RkxxU7kFS4?= =?utf-8?q?z31eI2YKNieeeWBD66QEjldE0esVPQHXRGfd8c3ZuekCf1jirQEMxR5y6tI89Id2W?= =?utf-8?q?BVTcfBplJcJN/h2zMmoGITFIwgGjyttm2Q=3D=3D?= X-MS-Exchange-CrossTenant-Network-Message-Id: 3fce9f2e-aa0f-413d-23b7-08dd105676bf X-MS-Exchange-CrossTenant-AuthSource: CO1PR11MB5057.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 29 Nov 2024 09:16:10.2867 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: i348vyt7LK7U3ZRYWURofleMgc3k5RaSyGAbMrVkCUWh8Lot/ma57uqYAKwxytTIV2zsVH9/gxvW8BQALhSu8W3WJPQQKNKsvSu22h7QopU= X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH7PR11MB6498 X-OriginatorOrg: intel.com X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development <intel-gfx.lists.freedesktop.org> List-Unsubscribe: <https://lists.freedesktop.org/mailman/options/intel-gfx>, <mailto:intel-gfx-request@lists.freedesktop.org?subject=unsubscribe> List-Archive: <https://lists.freedesktop.org/archives/intel-gfx> List-Post: <mailto:intel-gfx@lists.freedesktop.org> List-Help: <mailto:intel-gfx-request@lists.freedesktop.org?subject=help> List-Subscribe: <https://lists.freedesktop.org/mailman/listinfo/intel-gfx>, <mailto:intel-gfx-request@lists.freedesktop.org?subject=subscribe> Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" <intel-gfx-bounces@lists.freedesktop.org> |
Series |
[RESEND] drm/i915: add GEM_WARN_ON to remap_io_sg
|
expand
|
diff --git a/drivers/gpu/drm/i915/i915_mm.c b/drivers/gpu/drm/i915/i915_mm.c index f5c97a620962..8a2779191f18 100644 --- a/drivers/gpu/drm/i915/i915_mm.c +++ b/drivers/gpu/drm/i915/i915_mm.c @@ -146,7 +146,7 @@ int remap_io_sg(struct vm_area_struct *vma, while (offset >= sg_dma_len(r.sgt.sgp) >> PAGE_SHIFT) { offset -= sg_dma_len(r.sgt.sgp) >> PAGE_SHIFT; r.sgt = __sgt_iter(__sg_next(r.sgt.sgp), use_dma(iobase)); - if (!r.sgt.sgp) + if (GEM_WARN_ON(!r.sgt.sgp)) return -EINVAL; } r.sgt.curr = offset << PAGE_SHIFT;
Since we already have that warning inside `remap_sg` we can also catch this condition inside `remap_io_sg`. Signed-off-by: Krzysztof Karas <krzysztof.karas@intel.com> --- drivers/gpu/drm/i915/i915_mm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)