Message ID | 1516903859-3679-2-git-send-email-andrey.grodzovsky@amd.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <dri-devel-bounces@lists.freedesktop.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 5E98360383 for <patchwork-dri-devel@patchwork.kernel.org>; Thu, 25 Jan 2018 18:11:38 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4DCBA28AF3 for <patchwork-dri-devel@patchwork.kernel.org>; Thu, 25 Jan 2018 18:11:38 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3E5F828AF7; Thu, 25 Jan 2018 18:11:38 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id DCADC28AF3 for <patchwork-dri-devel@patchwork.kernel.org>; Thu, 25 Jan 2018 18:11:37 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 899FF6E587; Thu, 25 Jan 2018 18:11:36 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from NAM01-BN3-obe.outbound.protection.outlook.com (mail-bn3nam01on0045.outbound.protection.outlook.com [104.47.33.45]) by gabe.freedesktop.org (Postfix) with ESMTPS id D4C326E4F8; Thu, 25 Jan 2018 18:11:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector1-amd-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=M7saS0mUF8gKOJL6dw+fKqtKduo5m/B88dP7xQ+kDww=; b=c5g3VuBvHvhwCqS6eFH+3aYsX5ITcJTZltGknzCfNuD9RxHYEO5ESIzXw8or8METI4OBPZPr7Z960cH8EAd4aqU52p7CrN5CgnEy/KrRBjzGH8WaharV+JPt970Q+2Vv3AsnJZGyWwkEVyMKiKuzwa0oSdsK0FbAaIqnDDz+98c= Received: from BN4PR12CA0009.namprd12.prod.outlook.com (10.164.241.19) by CY4PR12MB1446.namprd12.prod.outlook.com (10.172.71.138) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.428.17; Thu, 25 Jan 2018 18:11:32 +0000 Received: from CO1NAM03FT013.eop-NAM03.prod.protection.outlook.com (2a01:111:f400:7e48::203) by BN4PR12CA0009.outlook.office365.com (2603:10b6:403:2::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.444.14 via Frontend Transport; Thu, 25 Jan 2018 18:11:32 +0000 Authentication-Results: spf=none (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; lists.freedesktop.org; dkim=none (message not signed) header.d=none;lists.freedesktop.org; dmarc=permerror action=none header.from=amd.com; Received-SPF: None (protection.outlook.com: amd.com does not designate permitted sender hosts) Received: from SATLEXCHOV01.amd.com (165.204.84.17) by CO1NAM03FT013.mail.protection.outlook.com (10.152.80.120) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.20.444.13 via Frontend Transport; Thu, 25 Jan 2018 18:11:32 +0000 Received: from ubuntu-1604-test.amd.com (10.34.1.3) by SATLEXCHOV01.amd.com (10.181.40.71) with Microsoft SMTP Server id 14.3.361.1; Thu, 25 Jan 2018 12:11:30 -0600 From: Andrey Grodzovsky <andrey.grodzovsky@amd.com> To: <dri-devel@lists.freedesktop.org>, <amd-gfx@lists.freedesktop.org> Subject: [PATCH libdrm 2/2] amdgpu: Fix segfault in deadlock test. Date: Thu, 25 Jan 2018 13:10:59 -0500 Message-ID: <1516903859-3679-2-git-send-email-andrey.grodzovsky@amd.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1516903859-3679-1-git-send-email-andrey.grodzovsky@amd.com> References: <1516903859-3679-1-git-send-email-andrey.grodzovsky@amd.com> MIME-Version: 1.0 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:165.204.84.17; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(376002)(396003)(346002)(39860400002)(39380400002)(2980300002)(428003)(189003)(199004)(48376002)(50226002)(50466002)(6666003)(47776003)(68736007)(2950100002)(106466001)(5660300001)(105586002)(104016004)(8936002)(305945005)(8676002)(356003)(81166006)(81156014)(186003)(53416004)(7696005)(36756003)(110136005)(16586007)(54906003)(316002)(97736004)(26005)(51416003)(59450400001)(4326008)(72206003)(86362001)(2906002)(450100002)(53936002)(77096007)(336011)(76176011)(478600001); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR12MB1446; H:SATLEXCHOV01.amd.com; FPR:; SPF:None; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; CO1NAM03FT013; 1:sem6nP+1hsO2aMeZiavy6nFDucMwldersghFxCBB5ysLF2CcRT3icPD4N8ZptU5dBCrGrfTuTcReMxevRTfnjKlIC1VSS9lT4ZjjRtjM/tjKCBEHxtArBx9lTKTLAMe5 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5a1493f6-25bc-472e-6e2c-08d5641f1041 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(4534165)(4627221)(201703031133081)(201702281549075)(5600026)(4604075)(2017052603307)(7153060); SRVR:CY4PR12MB1446; X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1446; 3:USy+KUeOCNPgg3LtlqN56RAhKqVBROaoFq/E/gZwu3vlb9eY1PN1+2je1/kjz9EdLsmi/CaI4mtiy6B9rKi6+JbVP27B9iu9b01Cqsj6lCLmlr7AkwFHdnyGSPkS1cdt9i7wC0EZdy9keCTRQdTFwmdyCuKE+q4/h5TfFAjP4Qb/p7dSYTuAGovGWrrC41Mtx1s7sp4aDqSXEFU+Csa3gyIpocXdsSJNXF4iRZsc2XxE1H0recwXULF2LJdxvXBlve9sjPDDkqWVxtvjAixdI6qnxkRADRHI7v6lqdKW7Wapo0t4InlBc39CsCemXerh+o2LFGdzktU++OU3z0KfTkSkZYZQvwQSuK0naNnv61I=; 25:TofhmmC/yesOc92jY1oRN3dZvZtPns65wNQPiHrDBwmic/gbdH7VM6YDTeZogKvXl6B4HptIYRDDOEsNUam54eFGPFIPeqbANr0PtcDrls9tHz9Tr7JVOYNs8nNxXb+INNDek1RIcgmLN4s9HUCJOHeVV/KxBjDuldgwcn0v6SBKBbVzn2lR4ED+yydoTik0MbJfghvJ/1YHkQrIwk0fgsoSF6pRnqoBSI28y07MC+6aTHqY0ASWqUlXknsZ4TTpsgMlxrRDFXNy+QvejU0oruMTNm7suhwg8QgslLbDgh7jYjtZ/4sA8FtnZZrYPGydXyJpC8V26k0s8Q+Z6YbinA== X-MS-TrafficTypeDiagnostic: CY4PR12MB1446: X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1446; 31:XKXJT39aWj6CutL2ZO97qj2ta1RwlJn5VQHTGAJia2QpSmUQZ+FrLB1gIDGtsFG5o+IakT2EshoywNIpvcRvFXpNp+sFQ1F7Na1qhOQIUNt/DEPyJ7pSJVZKg2pR0sGZR3aV4BDRd0V1qN/AYgFfGgQUpzClLl1i2/uUG61aKiS7BBrHsZVWhNr/EqMRyWINqHg+KNeE5IiIOtcx874lM0S8D/TUb594283+qMzutMI=; 20:rGuzeUwuvpd9pCF0FmKi4l9MyxCMsEjtYotQFy5WfoPwrwcVPmVu6w8x7sZSoB8hg9CwuXpfVIyRqdryliWF+BXmW3vKofhRfUq+MgFyW2eteDbDCa7usVKSgzU8bVohpE+4Zdi3N4lu89iBA0HWzboLVbcztUCrqBmVMeqMO/1xt/57r2O4MyIyQN4wp/6fUVsigPDcOkZfyXpSRcRuDnkvnhc0yu+dOZEJYHkQGclu9hjh5NSA6Uijt1RJQeUCsiV7j/U7Ty3wAueyuENsJFC9hZOQ+zXh4W8zfCzKj3PUtALc8/YGiYSXmPGEfyuVXlE+s0OG4NFbIllbKQCWtzFfCar/qNJ9oeIjqFumv6FT3WqTHFwNXvBIvzSy08jxzigk2JTDWAm3kvSkNDrf4WzD6tLtxM2FVEnUW8bo+eLebjme1FfHMZZIzzgfHoIflXK61ECaUE0Td4jectAUcoEpPbgYd3pbLXFGY7UXrLn2KpF8xrIeo1D/ZAYPoMGo X-Microsoft-Antispam-PRVS: <CY4PR12MB144631717CE9A4B31D181BFBEAE10@CY4PR12MB1446.namprd12.prod.outlook.com> X-Exchange-Antispam-Report-Test: UriScan:(767451399110); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040501)(2401047)(5005006)(8121501046)(93006095)(93003095)(10201501046)(3231023)(2400081)(944501161)(3002001)(6055026)(6041288)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(20161123562045)(20161123560045)(20161123564045)(6072148)(201708071742011); SRVR:CY4PR12MB1446; BCL:0; PCL:0; RULEID:; SRVR:CY4PR12MB1446; X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1446; 4:1VnjmGnmDm/pRCRulyfq7Y/YmB3LE0jlumbzQNSscQ/+s8bwgq61OAjgYgnaT8Zpiq6AXu+3TH8+njbcFSuC0Ee63lvxZs4RsluBJ3tet3Tg80cHN3k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gCPVCRQ+ynMwb5IIs523AxAQQtZQnItZ+S/REwWW4FLZPF8wAMHYQk4C3Gs3mpWDA158MmBVduFVxSBWKibfes1nReFjb9jsavP4xplDrnU=; 24:2Tlz0g/fYkTCczN8X/pm1UTuWPVHO/qlKP3pV7SigC/T/K8rP1nhdQyrarmKFTwdeNZVz/DY9llPc/vjxHb1KVmzV/3kQVoz0GRKL8/a23c=; 7:15zPv1GWy3sTbaUyfa+lutnr+SM46/oU8TbhpcxduDz6+6jearDJ2L/4cYCedm3gOBRBGvTV3QTLHx0UP5oUpYQa34MjJG63W8muR+zRL9l0/b+p6KjjmTFEM5OGIxDFW1DNGRtCJOQjq05nSJRMmzm3N08RBYI3LSbvmXBYtmYv1rNT4wk5JXgO9KEg+KCSnuS112g/lIUo2YuurcIpppc2WLWX7qwhFJJKI9n/S59s26bmluXer084Nio5b4n0 SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1446; 20:7HltaVFmoL05B526twnvejGMhp0L6YGzkzpUOeRWr/EY6fAE8GklVc6+wNTvJ53d8IDOpPZtIq+DCZjqsW+c5/QPMuT2SGeVoCkWN299fd+rpcmccVFYP4JFZM1dokKlHqfQxiuvcH2PFOCSBLdrQIcp+gxEvImadrHK1FwNFSFvDS/WvLZVNHAGJbZxh85rNublE+1QOXzq+pQmysHvmlkZIxg3lfADHG1Pwvfkvm239nSPG8zp/kUcugrfvAoS X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Jan 2018 18:11:32.0404 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5a1493f6-25bc-472e-6e2c-08d5641f1041 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXCHOV01.amd.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR12MB1446 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development <dri-devel.lists.freedesktop.org> List-Unsubscribe: <https://lists.freedesktop.org/mailman/options/dri-devel>, <mailto:dri-devel-request@lists.freedesktop.org?subject=unsubscribe> List-Archive: <https://lists.freedesktop.org/archives/dri-devel> List-Post: <mailto:dri-devel@lists.freedesktop.org> List-Help: <mailto:dri-devel-request@lists.freedesktop.org?subject=help> List-Subscribe: <https://lists.freedesktop.org/mailman/listinfo/dri-devel>, <mailto:dri-devel-request@lists.freedesktop.org?subject=subscribe> Cc: christian.koenig@amd.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" <dri-devel-bounces@lists.freedesktop.org> X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/tests/amdgpu/deadlock_tests.c b/tests/amdgpu/deadlock_tests.c index 9a42885..fc49c48 100644 --- a/tests/amdgpu/deadlock_tests.c +++ b/tests/amdgpu/deadlock_tests.c @@ -245,6 +245,8 @@ static void amdgpu_deadlock_helper(unsigned ip_type) AMDGPU_TIMEOUT_INFINITE,0, &expired); CU_ASSERT_EQUAL((r == 0 || r == -ECANCELED), 1); + pthread_join(stress_thread, NULL); + r = amdgpu_bo_list_destroy(bo_list); CU_ASSERT_EQUAL(r, 0); @@ -254,6 +256,4 @@ static void amdgpu_deadlock_helper(unsigned ip_type) r = amdgpu_cs_ctx_free(context_handle); CU_ASSERT_EQUAL(r, 0); - - pthread_join(stress_thread, NULL); }
If amdgpu_cs_query_fence_status terminates prematurely the BO sometimes is unmapped before helper thread writes a vlaue into it causing a segfault. Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky@amd.com> --- tests/amdgpu/deadlock_tests.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)