Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753309AbdLMO4K (ORCPT ); Wed, 13 Dec 2017 09:56:10 -0500 Received: from mail-cys01nam02on0056.outbound.protection.outlook.com ([104.47.37.56]:19104 "EHLO NAM02-CY1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752879AbdLMOzx (ORCPT ); Wed, 13 Dec 2017 09:55:53 -0500 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Vadim.Lomovtsev@cavium.com; Date: Wed, 13 Dec 2017 06:55:47 -0800 From: Vadim Lomovtsev To: "Rafael J. Wysocki" Cc: robert.moore@intel.com, lv.zheng@intel.com, rafael.j.wysocki@intel.com, lenb@kernel.org, linux-acpi@vger.kernel.org, devel@acpica.org, linux-kernel@vger.kernel.org, vadim.lomovtsev@cavium.com Subject: Re: [BUG] acpica: ltp_acpi test case causes kernel crash at acpi_ns_walk_namespace Message-ID: <20171213145547.GB6692@localhost.localdomain> References: <1513094360-1414-1-git-send-email-Vadim.Lomovtsev@caviumnetworks.com> <9523980.S2jPabPoO5@aspire.rjw.lan> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <9523980.S2jPabPoO5@aspire.rjw.lan> User-Agent: Mutt/1.6.1 (2016-04-27) X-Originating-IP: [50.233.148.156] X-ClientProxiedBy: SN4PR0801CA0007.namprd08.prod.outlook.com (10.161.215.145) To BN6PR07MB2996.namprd07.prod.outlook.com (10.172.106.14) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: bd85ede1-cfed-4c08-c50d-08d542399a9d X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(5600026)(4604075)(2017052603307);SRVR:BN6PR07MB2996; X-Microsoft-Exchange-Diagnostics: 1;BN6PR07MB2996;3:J9oprIp4CO6Iv7VeKjEPU+8ToE/ahWjIrCgL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2S6Ox0Jk7yhcb4RN0eCzy58jLaWy0TEcz08+U8KUy+ku+YClpO762mB4RBWHYDSLoYAIo/czl3ml3qZLOz87PNe1KOv6TIkRZATArqVAQ4h7EZT9Hyu923itxYGX5ALbXLW0JesIk9mk1Lrtx9KlOYMd6wTNrtHJWPAgKMmZlLoSaMtSh/jHGi/E2LggglMx/abBq+MyUHFN1Y5pWZhTsw6SUoemiZO2VV9NqOeNkMaQfJSLms1LLjv0ukZtIawaXkW+5uQ09a1E8e22zb4CxwEza515eexmR/ZowO2CE0dmCxyZNcCzcS+YPq4KLWIrS0Oo2c1aLjCU+mFFp3VdWRU/WCUJGvo+jXJYbChfBHJC13N1BrrT49WrFKm+ECB4mq+4X4vE1DlfOGmE/1686F9tgcNyyYbPmvTEQYEwCs/c=;4:bd6ARiG2a6QqSbxs/7IL5eed1gvmSINyvKO0MtgqwASiwJ7GkgzEFIozrydRJhnI+w+/b7q949uS4gkyD04IpxU8sEykW055Qko6Rzy64aBOH7/P5gZysFe7rloSeaAWFtUrvMn9gn09tVpG8BdN+NSxTCAOApu//9vqZ2j0VnZAVGQB+NSYckx0SscgVMmrQS5GR9yHVy+gqcjjPbdYCM+yxUQgaA4kLhzwTkbaIyIG0YoX9QROnHshvbxotWM6nCIXSxpiUks4P+Hm8H5eTQ== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040450)(2401047)(8121501046)(5005006)(3231023)(10201501046)(93006095)(3002001)(6041248)(20161123558100)(20161123560025)(20161123564025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123562025)(20161123555025)(6072148)(201708071742011);SRVR:BN6PR07MB2996;BCL:0;PCL:0;RULEID:(100000803101)(100110400095);SRVR:BN6PR07MB2996; X-Forefront-PRVS: 052017CAF1 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(6069001)(346002)(366004)(376002)(189003)(24454002)(199004)(9686003)(6246003)(68736007)(55016002)(52116002)(47776003)(478600001)(1076002)(66066001)(61506002)(3846002)(6116002)(23726003)(72206003)(33656002)(6916009)(6666003)(106356001)(97736004)(2950100002)(42882006)(229853002)(83506002)(50466002)(8936002)(105586002)(81166006)(81156014)(8676002)(107886003)(4326008)(33896004)(5660300001)(16586007)(58126008)(16526018)(53936002)(76176011)(2906002)(305945005)(7696005)(25786009)(7736002)(316002)(386003)(6506007)(59450400001)(53546011)(18370500001);DIR:OUT;SFP:1101;SCL:1;SRVR:BN6PR07MB2996;H:localhost.localdomain;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;BN6PR07MB2996;23:zTccO2t8V0B6xZtHkrhojwKF5I+UueiesgEtljg/3?= =?us-ascii?Q?YtK99mknqgmu8I8DfbqMv3gx7hVUMmFoKJTHhL6mERiz4/GJ74lhjoIbRVnk?= =?us-ascii?Q?MHCvuRGjvDpiXLaRqrPYWnAOikI+qR6IRr4gtleGqWplSEsouSj47bQjK3Oy?= =?us-ascii?Q?/Qf1vYX6JjxnopVbVft9bTFdczGM0JfY0aYkGT+P7aM4lKEDhrDXrM4DBJfd?= =?us-ascii?Q?4NyhTF8CoEQl2+Hw15vfXQ55mzR8OyhLO5Fd8isgFoWY7v8eMd0xWHM4y7Zy?= =?us-ascii?Q?ZpYo2zsFVZf8l6a1Z+jq9LacJ2c93hiC7V3+1e9e0oND6gub7PSosg7Q7Rbl?= =?us-ascii?Q?leFM4cODo1bOufvW7GO2Y/wTl3pmEtbCWP/qmzV+ro43CnZPlChadwp6vj3Q?= =?us-ascii?Q?i2RnH2i2NpjXrJL+bKzfWvPHpl8hqEiCYMd+QhyA8ehlHmkLefAl75hy6j9m?= =?us-ascii?Q?HEpTSycr8p1iQ3CMdPOs8KbUg51E+Sjx/gdXT5YxJ5NoIlN1BrbUAjdh20yM?= =?us-ascii?Q?xMAbtVZVy4/Bmf8k6mxlqGbNyXKdjS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J6/B0EmZm5ocbIo96U/4BeT4uZQd68LqFl13XM2GIaNiEoiYh/YfDZuJzw3rQ82b3i7J44r0oYP33eyye8Djkn2fgp4qEP9QWGRWNtAmVi90HqavO/rjDm9+s6tlqMEf0unsVlEInZxVyrX9/G3GtHw+xGgI2JbRSf1xAwgBI2Fw6aoPYPGTKeT1RAtp0Dm/Pb29cWwXr3NDg2CrP65Wm6CqdClBn2rE3KGBZnvLy4WlubdNTUm+ysem76S+nA3tM=;5:Fc1Ki1DG6qzRzix//ADHO1dT/coBZahFPrpLDnF6Te+orLQkOgp+a+6I+mOlUP6AfhJLzdHC/KVFcq1aFxTqnd8/un0YSuTB/oQFu9X097izC+guQBsztO54Vp1plEbpKbVaTfZCPYVubrRJRUFndOaG6E3IPnk+8USJ/HlYeUs=;24:dpCNesSOA3s7JxgoEL5ToYTIy8ltt6bGbIZhvkcAJ+GG719KPvVH16TLCeqFQkoV5bOmskKWG1bnzrZKtbXmiKypAjNFFSA2RBb+4Q/4hnw=;7:V7UTuz9mpuQWG964lSFTgECy+cPwjrqlsmBl4FFSe57TaK9HkpsGZWhekcRQDD/hI8bkOiKvTbmpJUXS33uku2sYsdLMTwcqIZyTiX2VFme6wdaRB/6oivDut5GdccfT6WLuubiMdNHSSlIRV73arzu5DywQ9Cwhy96QzFrIl1lHFIPV0f3lGgJvxFxqMeqaj2BKN1fZxOFff+HEt34z+VZn7B6vpukWIepX+VR9VP8DF4MQJRsJkdBgym9Zc6BQ SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Dec 2017 14:55:50.8799 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: bd85ede1-cfed-4c08-c50d-08d542399a9d X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR07MB2996 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1359 Lines: 36 On Wed, Dec 13, 2017 at 12:45:50AM +0100, Rafael J. Wysocki wrote: > On Tuesday, December 12, 2017 4:59:19 PM CET Vadim Lomovtsev wrote: > > Hi guys, > > > > While running LTP tests I've faced kernel crash caused by ltp_acpi test case. > > I have ACPI support enabled in kernel but kernel is boot with FDT having ACPI > > disabled. The ltp_acpi test case application is built along with ltp_acpi_cmds > > module to run ACPI tests. > > > > So my question is - should we update acpica implementation at kernel side by > > adding 'acpi_disabled' variable checking to the 'acpi_get_devices' function (see > > patch next to this email, maybe not a good approach) or this should be fixed at LTP > > side so the ltp_acpi_cmds should be updated in order to check if acpi is enabled > > before running tests ? > > There should be a check preventing acpi_get_devices() from being called in the > acpi_disabled case. In my case I have to update ltp_acpi code then. > > acpi_disabled is Linux-specific and the ACPICA code isn't, so the code calling > ACPICA functions should check acpi_disabled when necessary. Agree. However getting back to LTP tests it looks like such calls were implemented intentionally without checking of aspi_disabled value. Don't we have any self-testing stuff in acpica to prevent such scenarious ? WBR, Vadim > > Thanks, > Rafael >