Message ID | etwgucaj4hu7buvrvzgxkhxjtl526qd6fdyfmxzsdacphrg667@nrd35hese3t5 (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 46673D58D5D for <intel-gfx@archiver.kernel.org>; Mon, 25 Nov 2024 15:27:24 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id BC01A10E011; Mon, 25 Nov 2024 15:27:23 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="iuPXt1RV"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 21C8B10E682 for <intel-gfx@lists.freedesktop.org>; Mon, 25 Nov 2024 15:27:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1732548442; x=1764084442; h=date:from:to:cc:subject:message-id:mime-version; bh=PmoiDz4b7ZIUSCtn8LfR3rdhZJPjpFpBvTH0vN+6Or0=; b=iuPXt1RVukOmJFQfyVwSix5xKIJnxnkeCY6ZvpPK9w9mtCsWVf7F5yz3 C5Bwc5LPmWKlVntsETSwSDpfxIsrf5IYi3aF3w99lSPSSuxD0rt5kC2Jf nsqIPAVVnApNvnTxa4tQez15VRYuGJgtFhxTgzck5p5EuGV/DuTNIq3iq T+o/TMCG71TDBX6WKcc8dyuTsZAlrq5XRoOL5rCFVLB3zQYZv8JzAKq/l 0T4k+ItHQzn5Xl9Yod2rhllXUcT1fIdw9L46c7uKnip1y57HVJlV9Ua2a ZKnfqHBkDGySZ4feiZtPfV/pVF2nu+JcOpYciYMHKyZl2yz/L41mrFeQC g==; X-CSE-ConnectionGUID: D/RJpYqLSouyWJCQ2LFtmA== X-CSE-MsgGUID: W6/OsrLJSRmYwF5udf+kGQ== X-IronPort-AV: E=McAfee;i="6700,10204,11267"; a="44042725" X-IronPort-AV: E=Sophos;i="6.12,183,1728975600"; d="scan'208";a="44042725" Received: from fmviesa010.fm.intel.com ([10.60.135.150]) by orvoesa104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 25 Nov 2024 07:27:21 -0800 X-CSE-ConnectionGUID: 5k9dl+cZS32m33ltbF7TKg== X-CSE-MsgGUID: w/fFFCUkT2SPHoKr+6azUA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.12,183,1728975600"; d="scan'208";a="91636983" Received: from fmsmsx603.amr.corp.intel.com ([10.18.126.83]) by fmviesa010.fm.intel.com with ESMTP/TLS/AES256-GCM-SHA384; 25 Nov 2024 07:27:20 -0800 Received: from fmsmsx603.amr.corp.intel.com (10.18.126.83) 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; Mon, 25 Nov 2024 07:27:20 -0800 Received: from fmsedg601.ED.cps.intel.com (10.1.192.135) 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; Mon, 25 Nov 2024 07:27:20 -0800 Received: from NAM10-BN7-obe.outbound.protection.outlook.com (104.47.70.40) by edgegateway.intel.com (192.55.55.70) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Mon, 25 Nov 2024 07:27:19 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=Rwc14/pmz5EzN1PkPNcbiU4Ce0FOM2UgVsixNVmrhiXtXlXx9ey6/PlgyxnxE8NOd1wWBzPuABkWBM/+uzSk9fkVB+3TymZjjCWbw1t0OyhItBoCV7MxrKk4GGuEUA2ex0Ami4nGvA3fQY47X6tLn7wKvW+1/WI6mqtEjmPkcKc+BYY5oeulB9IkG3qcs3N7cE6AKWtjWUSV7TQQYbvaCAozwzikMj4chJYDAxIc+4dkClAdxoKatz406Fqjas3w00YRuu/FwXf4ubkB4lif0m0Movp0wa1pSGwhI3zPZBqDxTBsZTC97vCfaFq8Sl/aEpMnMJRyqAXtpuWTvTmWlQ== 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=e3TRzhBFNbclh/lJNYDVAGV7F5iNz98selIs4H8XoVU=; b=UgD+M0phSFOf7o3Oxj4ByQBPfDLA1mY1NrWI/kON8mCSdLjCmaEPVfBnM424SKIRuz0ubG2681Ycvmugx+uhEovkfStj2y0DQ0lyBHY9/rSVc+b3RyEX12sJoG80Y9KvXXlzNI/phAGTR6dSxmJOczYpbK1smO2aSPYf7Mxi6aqxpmwNPBAh4gLMyL8GiYrBtbtwnLHxvRQWDQHyCdmmTcRTWnwFR03y2jbPu7S1z/6vBWE5eUVfZv0QBLLuuA/kPl7S0dFFkM0JZqTedvuvQ2z04hnrFfrXAyT+nqPl0gpp6B5JrF/GFZ5GRNEkF9z7YiEcbdb9AL+5ty1jBLrXjA== 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 SN6PR11MB2640.namprd11.prod.outlook.com (2603:10b6:805:56::11) by CO1PR11MB5059.namprd11.prod.outlook.com (2603:10b6:303:9a::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8182.21; Mon, 25 Nov 2024 15:27:15 +0000 Received: from SN6PR11MB2640.namprd11.prod.outlook.com ([fe80::4b8:af61:4cfe:d6fa]) by SN6PR11MB2640.namprd11.prod.outlook.com ([fe80::4b8:af61:4cfe:d6fa%4]) with mapi id 15.20.8182.018; Mon, 25 Nov 2024 15:27:15 +0000 Date: Mon, 25 Nov 2024 15:27:11 +0000 From: Eugene Kobyak <eugene.kobyak@intel.com> To: <intel-gfx@lists.freedesktop.org> CC: <John.C.Harrison@intel.com>, <andi.shyti@linux.intel.com> Subject: [PATCH v3] drm/i915: Fixed NULL pointer dereference in capture_engine Message-ID: <etwgucaj4hu7buvrvzgxkhxjtl526qd6fdyfmxzsdacphrg667@nrd35hese3t5> Content-Type: text/plain; charset="utf-8" Content-Disposition: inline X-ClientProxiedBy: MI0P293CA0004.ITAP293.PROD.OUTLOOK.COM (2603:10a6:290:44::15) To SN6PR11MB2640.namprd11.prod.outlook.com (2603:10b6:805:56::11) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SN6PR11MB2640:EE_|CO1PR11MB5059:EE_ X-MS-Office365-Filtering-Correlation-Id: e53d8096-c535-4cfe-71f5-08dd0d65a3df X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|366016|1800799024; X-Microsoft-Antispam-Message-Info: =?utf-8?q?7XM3bPc7wjCvnX6rRRcDYwKVAK0AdNy?= =?utf-8?q?7x+18WLk3aYVp+L0g7MvS4sAhjmjuenB/1J4agjQtuAeF8UK64gg8UhNE6QlNXigN?= =?utf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q?Fcwx3HC9DQZIGgnWIIQFg4DU27pmWqchswyEFev/pIAti2D12PgAGe9N5+8yu+Bgp?= =?utf-8?q?Fh/NshaGy/aOFikKCzJyX+yv5FMq8Qtg89119abh8oC2qQDpa8O1cMEiPxZuP5Hl2?= =?utf-8?q?DFC2m+r0UrPinIu+sdIoFHq0owACaPlO8JJ8YrOqhicqmI3wyrVGXYOm7Q4D82FKD?= =?utf-8?q?xAEUrTq6fPGExbFcAyLgTu+zPV7lFmpSdJ39/N8ioUiQtZPBoO4XjC/531S5flGWG?= =?utf-8?q?BdiaHt4uE0nVH6t2/ec8T912op1W/weVW7H6oyQA9cIt9BxJH+A74WczE=3D?= X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:SN6PR11MB2640.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(376014)(366016)(1800799024); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?q?0Ez+Tcqnt3XQACv9HAFZ4cmbKfZk?= =?utf-8?q?ySSlYKuuudHXpaAQzJri4ft1JNAWxldbXoW1l1gt1y31W5FE1Cjvgmj7X5YqQ/XWO?= =?utf-8?q?wd5xkXhTTqXHg7CvLKhzroMDgSiMs4rWHQhHG4PTwxUff5+KQOK8ZCWXHJ8M9ajqy?= =?utf-8?q?6+u5Oj+w1Igbm9BXx6t3ogES4vGtNxb7P74ZDgDfccv7lP5YvCnc4PAqjdhMVJXC5?= =?utf-8?q?ctlvU314ja7ABti4/o/ik58cTBOTRpwKjlp+k/bMDhOr1e+mXXJ38gRv+Cb5S4uZd?= =?utf-8?q?LxBrmH5yKORR96TBRqB3fUbym8Rl8wX5aTLzHYm01TKXaUd9vWqw59hsM0VvbYQtW?= =?utf-8?q?dIcjNuzdB1olCXqNdLMnP69WZoqS36m631fI15LzTWW8vpYjnMbRrjkceTC87UN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-8?q?yJNUQTrOtSHeXLQDp9rydxpVOl6S/lFsf+SSeMo5A3yK6uzXgHhqnd61UpQpLub+x?= =?utf-8?q?WP0wUS2O3PMJglIr8ohyp8lm1y2CdytgZSK0k3Gwx7Kzwx3a0gwwUe8BdbPok1uCu?= =?utf-8?q?XJTr/LRHWad8qB8Lk63EA+NEZeMRglKnMuRKJ+hm41+n38+OR+PLpWMV+sJmx9fLi?= =?utf-8?q?Han2/LL79zKapuSFwLLDFHTt2lr+8R0aMoYMF78mVz4cGlZcp0TbLeuJbPw/gCMc5?= =?utf-8?q?tcyEQ4HBd8DwLnbo1Er0ucUn770J5eaq1g=3D=3D?= X-MS-Exchange-CrossTenant-Network-Message-Id: e53d8096-c535-4cfe-71f5-08dd0d65a3df X-MS-Exchange-CrossTenant-AuthSource: SN6PR11MB2640.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Nov 2024 15:27:14.9624 (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: WaPqWyYPCiHCF4VrnnSKaKGGKldAW47Uu8EfipzjfR7UqSk3im4Zllg5NTHIvC3yVhVdAQ8iMRiCCxoL1oCzEw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO1PR11MB5059 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 |
[v3] drm/i915: Fixed NULL pointer dereference in capture_engine
|
expand
|
diff --git a/drivers/gpu/drm/i915/i915_gpu_error.c b/drivers/gpu/drm/i915/i915_gpu_error.c index 135ded17334e..1c614c74c2cf 100644 --- a/drivers/gpu/drm/i915/i915_gpu_error.c +++ b/drivers/gpu/drm/i915/i915_gpu_error.c @@ -1643,9 +1643,16 @@ capture_engine(struct intel_engine_cs *engine, return NULL; intel_engine_get_hung_entity(engine, &ce, &rq); - if (rq && !i915_request_started(rq)) - drm_info(&engine->gt->i915->drm, "Got hung context on %s with active request %lld:%lld [0x%04X] not yet started\n", - engine->name, rq->fence.context, rq->fence.seqno, ce->guc_id.id); + if (rq && !i915_request_started(rq)) { + char guc_id[9]; + if (ce) + scnprintf(guc_id, sizeof(guc_id), "[0x%04X]", ce->guc_id.id); + else + scnprintf(guc_id, sizeof(guc_id), " "); + + drm_info(&engine->gt->i915->drm, "Got hung context on %s with active request %lld:%lld%s not yet started\n", + engine->name, rq->fence.context, rq->fence.seqno, guc_id); + } if (rq) { capture = intel_engine_coredump_add_request(ee, rq, ATOMIC_MAYFAIL);
When the intel_context structure contains NULL, it raises a NULL pointer dereference error in drm_info(). Fixes: e8a3319c31a1 ("drm/i915: Allow error capture without a request") Closes: https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/12309 Signed-off-by: Eugene Kobyak <eugene.kobyak@intel.com> --- drivers/gpu/drm/i915/i915_gpu_error.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-)