Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp131302iob; Tue, 17 May 2022 21:16:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwSOLPDfvnJInWgM0MUrS3OO1+k6j7fRRP2VgeiK42LH4t6gfl7vWaBQU3a5qvRrXOlmkep X-Received: by 2002:a17:902:c40f:b0:15e:bc6b:6980 with SMTP id k15-20020a170902c40f00b0015ebc6b6980mr25140415plk.145.1652847409585; Tue, 17 May 2022 21:16:49 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1652847409; cv=pass; d=google.com; s=arc-20160816; b=yEsdRYmIpNWsBGkrOHnCrJQbBJq2HI9n621UhYkKAlNPwCBVdRhdxNbPqIS7vZE4TO TX8hjFr1BiMCMcek3vIWleK3ofvOafoN7a37pfNrGSg/Z25atmCb+z1j1YciAxvKTfyr XLvYX7cA8UbhDE65bsjUckcUZU3tP+Nf4EtXpN2ZGLpMLsuzaZmrUgZr62J2iWuqlDhd ESYsAmf7p7F9pyMjSCJnFldJHOSdmVHa021wkFjd+0JZJYgnmfO+SSuGmUPQfSkJ2Mft m8nYTh5++wZj7V/iEHj+SYABqKBfM6ohnHvnG1bpjJgM/VAoYm3J2qkkvT8++8VMDTG+ /bHg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :in-reply-to:references:cc:to:from:content-language:subject :user-agent:date:message-id:dkim-signature; bh=5qyipFKu+Ew/EPnKfZCoihis4KISrOcpakaHNYbuaJY=; b=VKKu7wpBRLHDja9sdrsrR0rGgNI70rX7UNsb97LiU6vSQ8uXW8T1Pe1TlCZjcbFM0+ vMj27yhi0hL94hL5wxmVgNPg2OF1cBHLhdoyN1vaZ9uoAWi82Dt5l7ZKTHmaPz12B48m r6zELcoEJf2zITo/1QPerh4CC0U76z8uDJ/2mfuozoAM2wYFkJkT+xML5wrO6MoySrg4 dZLEmPvNZ2LPXE89SruiG5LJNA619iKJrU9TW07UCJFQeCPNT5BYZ8CN73JsQI5uHEsT OnHFG22EHqQcxyiHZ736uxyMZpK6lBkxswdAQp+ZqFsdzIO30C3ekgbjkl283EjrG4YC Vlrg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amd.com header.s=selector1 header.b=rat0bhDq; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.com); spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id m8-20020a17090a730800b001dc8b6d4936si1306982pjk.11.2022.05.17.21.16.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 May 2022 21:16:49 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@amd.com header.s=selector1 header.b=rat0bhDq; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.com); spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 85F5F9E9C6; Tue, 17 May 2022 20:45:33 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234360AbiEQONb (ORCPT + 99 others); Tue, 17 May 2022 10:13:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37672 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235171AbiEQONY (ORCPT ); Tue, 17 May 2022 10:13:24 -0400 Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2074.outbound.protection.outlook.com [40.107.93.74]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 68C3D4E3A5 for ; Tue, 17 May 2022 07:13:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=fq4uWOUaibbNCHNKYS9I/uFXItmWPJF+EuJGjg31NTJRJGzIvTYJxP3UHXa5qqiCMEZYU3vAIbHpKErEjmEZ2hnTneOshYZLRiOL+yPWe32CAJd5bSuUEKFRcHPb9rNdYHzDkKmzNek1DAupocSlf3Q/JmfgOyaRMrBJ3tlMWOUQ7jo40yos/l6fqgIcudxIRFYzWVElEz+ImGZIUxN+JtCTv7wSUOVIKPVvneW1FNVfgaYgcIE0zseYsKMxJnmiSaaDjLYNWvR60Rz7W/50/BsJEwzbuOcbk5Rqo8OU0TD1qKx2ysXV/fIarHkds/Q8eho604t6nlEku1jVng1SoA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; 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=5qyipFKu+Ew/EPnKfZCoihis4KISrOcpakaHNYbuaJY=; b=SEEmDBXuPA2nONkZzanVQ12rHL0AvHatyDdcuPIBUdb6hcTFGROv2YTKMfwy7L4StbTi4v4TLzTBTj/tT8NbN2U3BfL5MraozEK/SaXi/xzBCBZ4nZtdOVtKdh1otecR/TqEjpAUgsNe3xVroQ2werKMT5sPD7RJxud73k8GIvIph0613+KMuhTOc1/EdGSx6GNOMvZMT6/oQFq8UASjjgCmTv1elGDdRoytAJoAhBWp3EIfDwFyuvnq5F/3R2YYotPmhac4Gon/KcFq/5Lc/jz5cUBmXEuWns9nP4g52/Eq5Ww1XLZ/KoLfHFe89jbALSjJ67TeCm73inaA+vtE+w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=5qyipFKu+Ew/EPnKfZCoihis4KISrOcpakaHNYbuaJY=; b=rat0bhDqPOkWviC/9GAdxwlwdmYq3924M6Gvh1+IoGL+cNP6eQOFclZelKieDsGl3zmXvYvVyjlxXcIGTtL1O6n+7Y811LpHDi59dKrhkb/qOqQ05+vE1ilDz6qWpi7esHz1yEXQE2voAjvD+OTtApAb/oyfRnQ3i/d2+Pvxf6o= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from DM5PR12MB1947.namprd12.prod.outlook.com (2603:10b6:3:111::23) by BYAPR12MB2903.namprd12.prod.outlook.com (2603:10b6:a03:139::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5250.18; Tue, 17 May 2022 14:13:19 +0000 Received: from DM5PR12MB1947.namprd12.prod.outlook.com ([fe80::9d18:7a38:7c5d:4a40]) by DM5PR12MB1947.namprd12.prod.outlook.com ([fe80::9d18:7a38:7c5d:4a40%10]) with mapi id 15.20.5250.018; Tue, 17 May 2022 14:13:19 +0000 Message-ID: Date: Tue, 17 May 2022 10:13:17 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.1 Subject: Re: [PATCH v1] drm/scheduler: Don't kill jobs in interrupt context Content-Language: en-US From: Andrey Grodzovsky To: Dmitry Osipenko , Erico Nunes , Steven Price Cc: David Airlie , Daniel Vetter , Tomeu Vizoso , Rob Herring , Alyssa Rosenzweig , Rob Clark , Dmitry Osipenko , linux-kernel , dri-devel References: <20220411221536.283312-1-dmitry.osipenko@collabora.com> <573fae0d-c9ab-98b0-c6f1-5b0d4e52dd01@amd.com> In-Reply-To: <573fae0d-c9ab-98b0-c6f1-5b0d4e52dd01@amd.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: YT1PR01CA0079.CANPRD01.PROD.OUTLOOK.COM (2603:10b6:b01:2d::18) To DM5PR12MB1947.namprd12.prod.outlook.com (2603:10b6:3:111::23) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: cbf46a35-867e-4a06-d869-08da380f64b4 X-MS-TrafficTypeDiagnostic: BYAPR12MB2903:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: l/eGiGHAGNl9CrDP3pkdqKjbTYMy1aQClZ1Qs1Ml5AfkoHdqrTIDuHs8Qt2/TEOHDWzML0dTVerIKdamI1acFm+IHRAMevjAHUYy2j9oscf/cCC3ybHANyU48JrRsh7+OFPkKwp7Bd9pWZJrewtz3xSBopm3ARiw/Zs/nl6tRD9IpJJ8CdoKR9Puc0ubk+2bfqqaK+UQIb2P0tz29ECqHyZ6VBLZHXeed7pl0W8h15fHWO1iyzrx7yGOiP2qd0jTUK8oKcjkJFMJiX6f79oGY8B3DlAryQJWP7zyDIaCeOCbpvOBYeEnT0bp7NqeEkzlmKNzAz793XGZAXx+bjl8oqS4R7hNWNeJBWmYfCXythJ1fTtlG8ps0VyvU3dud32e5i6KkFTN5TOPw/GLCVqjYCcnVPh6xpqCrSg1LoFtzg9KpJQGmlMtZ9nn9PnycLZMlqwrWebYuyjRDEZg66wg9Gg6v12LNdxyx2akBxYUBYcyWrxS/leYrL9JGb/HaQPXpnLbXrn93PCrP8S3QUBw6/wxaFPUCZ3NwRI7gG3hJtazbNL0jfs8j4Fdah+lkW2v4tsEUsvd+tD3N+XdqpHMCA+/0Tw8MGEd+wABSADkC93mdAMt+Slp1/9LdRrG0QPnyyFuXYWUZ96xRh223r2mdH2p5TKLYQd3hvlwIy8TSAsEfO/0KF4SckF+Yc4533DBIJJiM9M159j/8+SwUQQlkuPAvl67hQVCO8wRI4OZh/FZuD1E+XXIflrRFa4EQ8Ys X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DM5PR12MB1947.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230001)(4636009)(366004)(4326008)(66946007)(66556008)(8676002)(66476007)(6506007)(6512007)(31696002)(110136005)(53546011)(31686004)(54906003)(2906002)(316002)(6486002)(2616005)(83380400001)(186003)(8936002)(5660300002)(38100700002)(86362001)(44832011)(36756003)(7416002)(508600001)(43740500002)(45980500001);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 2 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?NElxU0NHelEvRVRabHNsREgvV1RCV2E0V0s2dW1OOHphU055VHZLTEZYdWNY?= =?utf-8?B?YXhKT29jT2Z3OXpLZ2NVdnRQaTJKNUIra0ZnbklrR3pXUDRrZDc0SW9uWXNh?= =?utf-8?B?ZUk0bksrUThvbjJBaWdtUFp5MW9ZK0lLZnkwNU55TGVSWE40ZS9MQW9ldGhk?= =?utf-8?B?dW83eCsxbVBDQlZVK3V0cnJ2cGl0WEhENWxRNFFXMnZsU3lwTVo2K3dMTWtS?= =?utf-8?B?RUhJeEIvZzNBMXNsditpcUZYQ3lId0V5cW5RanZvQ09OMk1BTnJJZm14YWdy?= =?utf-8?B?SmttbGpNb1I1c1ZnV0VQcXpHdmp0bjN0N1ltdVIzVVU0MWtndXYyYVp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DTmFDSDJNcWNQOUFiOWp3WFNwckFUdm9iZE8r?= =?utf-8?B?NnZhMFl0eFI1b0ZiKzdNY1FTaHVadTYwakM1Z00xcUNRZUpKWXVUZ2VCMXlp?= =?utf-8?B?MzJBSDhhOUxha3haWEpxVGk5VDBndE9yMkRBL0MyaG9CZ0ZsZThRUms1NGsx?= =?utf-8?B?bUl3elFjc1NhdTQvekoyN1VsVHMyRWpEaGM1TUl5eFBIQjdpVGgxdVVkMTZj?= =?utf-8?Q?CsiaQ6Qm31oRd91bDdyN52qpWGqru2vIJTfZ9SlKBbcmX?= X-MS-Exchange-AntiSpam-MessageData-1: p8fZIYXPh5pNXg== X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: cbf46a35-867e-4a06-d869-08da380f64b4 X-MS-Exchange-CrossTenant-AuthSource: DM5PR12MB1947.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 May 2022 14:13:19.3928 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: k8WQEMDmwv1u6xUiO9e5LmsLMRBZOYhwTSmyYmGJLZuqwyiCTl02D+XhYoxqb1nTsSjAVIbCssRLhZo2r62ndQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR12MB2903 X-Spam-Status: No, score=-4.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,NICE_REPLY_A,RDNS_NONE,SPF_HELO_NONE, T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Done. Andrey On 2022-05-17 10:03, Andrey Grodzovsky wrote: > Let me push it into drm-misc-next. > > Andrey > > On 2022-05-17 05:03, Dmitry Osipenko wrote: > >> On 5/17/22 10:40, Erico Nunes wrote: >>> On Wed, Apr 13, 2022 at 12:05 PM Steven Price >>> wrote: >>>> On 11/04/2022 23:15, Dmitry Osipenko wrote: >>>>> Interrupt context can't sleep. Drivers like Panfrost and MSM are >>>>> taking >>>>> mutex when job is released, and thus, that code can sleep. This >>>>> results >>>>> into "BUG: scheduling while atomic" if locks are contented while >>>>> job is >>>>> freed. There is no good reason for releasing scheduler's jobs in IRQ >>>>> context, hence use normal context to fix the trouble. >>>>> >>>>> Cc: stable@vger.kernel.org >>>>> Fixes: 542cff7893a3 ("drm/sched: Avoid lockdep spalt on killing a >>>>> processes") >>>>> Signed-off-by: Dmitry Osipenko >>>> Reviewed-by: Steven Price >>> Is there something blocking this patch? >>> Mesa CI is still hitting the issue and I have been waiting for it to >>> be applied/backported to update CI with it. >>> Thanks >> If this patch won't be picked up anytime soon, then I'll include it into >> my "memory shrinker" patchset together with the rest of the fixes, so it >> won't get lost. >>