Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751319AbdLSSG5 (ORCPT ); Tue, 19 Dec 2017 13:06:57 -0500 Received: from mail-by2nam03on0076.outbound.protection.outlook.com ([104.47.42.76]:25024 "EHLO NAM03-BY2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1750796AbdLSSGz (ORCPT ); Tue, 19 Dec 2017 13:06:55 -0500 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Christian.Koenig@amd.com; Subject: Re: [PATCH] swiotlb: suppress warning when __GFP_NOWARN is set. To: Konrad Rzeszutek Wilk , linux-kernel@vger.kernel.org References: <20171219143255.2262-1-christian.koenig@amd.com> Cc: Mike Galbraith From: =?UTF-8?Q?Christian_K=c3=b6nig?= Message-ID: <58a552e3-b730-2417-b16c-adde61812e79@amd.com> Date: Tue, 19 Dec 2017 19:06:43 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Originating-IP: [2a02:908:1251:7981:e06e:92f2:a681:d48c] X-ClientProxiedBy: DB6PR0301CA0059.eurprd03.prod.outlook.com (10.168.69.27) To DM5PR12MB1306.namprd12.prod.outlook.com (10.168.237.149) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: d8ca3c43-2404-4e54-0a64-08d5470b491f X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(5600026)(4604075)(4534020)(4602075)(4627115)(201703031133081)(201702281549075)(48565401081)(2017052603307);SRVR:DM5PR12MB1306; X-Microsoft-Exchange-Diagnostics: 1;DM5PR12MB1306;3:R4QzRoYAV/VqAZgY3emgtdG6vd8x+fMqxHLVQEy9T+Inwl+fmC/aQqBtXqy00Ajtd05ZzktJfIyQ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fduM8JfroXUrDqBDSeO6O5uWOCUp9Fz0D2jQygwVNFnwqziEvA8GZUhoQ+TneOqF6x+VQzgZFfmddXfSpqxDWPoXEKICCNZDARkwjrT7AD6h/MP4XNWHoMieDK2JhIPCC2wrLm7UZ49jJh6k52sdtwgv/gxEMFNiZXLKXuXZAgEmBWqmqBpgiQXvmfzDi/MNGrN7/Y5uFkc+YQclOY6tBGz54ZN7cPACR51aIjnLIuTYx5jiOteQqNjT8KP1cOH8qYARJ0SwfUFpscXd4eP41C2EjCzvKGiAXAgwj2n3;4:MTOBe8Cub2Mcj+XuabfSmeKQ2U9daqSDk0irZ4F96ycGoQga6MJWZ0bxXbSG/W3WHcMOTLv/cF63GF5rFutQ594tVKRjmuEsdAp9YHNg8ddH2XuXB3MnMQEjwnHM8kG/rhPTzCl3ulksWtVNdF4f646dBT3YzPUHGLVGD33/hXzZtBA5sjVW1g/pEyDCbbN0NZbwN1dtLRiEUezMgB4WdhE3zDTVWCOXR+LTkQ02F7kZKpN/Xo1xA3ozF24Hhc5HGqvlHzNWzJhsmYP3Z/+ZeVZji3NFnuxgaZ+XvTLF01kgAmUI7gg6LJWLiXry4OVolk24bKudCVBweouZDfmguA== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(26323138287068)(767451399110); X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040450)(2401047)(5005006)(8121501046)(3002001)(93006095)(93001095)(10201501046)(3231023)(6055026)(6041248)(20161123555025)(20161123558100)(20161123560025)(20161123564025)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(6072148)(201708071742011);SRVR:DM5PR12MB1306;BCL:0;PCL:0;RULEID:(100000803101)(100110400095);SRVR:DM5PR12MB1306; X-Forefront-PRVS: 052670E5A4 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(396003)(39860400002)(366004)(346002)(376002)(199004)(189003)(24454002)(2870700001)(7736002)(68736007)(5660300001)(105586002)(31686004)(106356001)(305945005)(64126003)(6666003)(2950100002)(81166006)(2906002)(81156014)(8676002)(65826007)(8936002)(6246003)(36756003)(83506002)(229853002)(6486002)(52396003)(8666007)(53936002)(50466002)(59450400001)(386003)(316002)(58126008)(4326008)(67846002)(76176011)(25786009)(23676004)(2486003)(52116002)(52146003)(6116002)(86362001)(478600001)(47776003)(1706002)(65956001)(97736004)(65806001)(72206003)(31696002);DIR:OUT;SFP:1101;SCL:1;SRVR:DM5PR12MB1306;H:[IPv6:2a02:908:1251:7981:e06e:92f2:a681:d48c];FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtETTVQUjEyTUIxMzA2OzIzOmVTUjhuVnBLTnBGcnNNbmJ5ZVBCR3kwZHBl?= =?utf-8?B?NndjMzJXVTR6VTB3NWcyNmZldS9NYmZxNzZFKzJGMmpVOFlmWUQyYUd1RWpW?= =?utf-8?B?TmVaY2ZhcmVFeWR5QTRQd1NibmltRjlYOTBoSjRrVG1Pd1o2SHNmZGZralAv?= =?utf-8?B?S3NnQlhJOW8va09jVC93R0lhVGUwck44cjRVREF5R2ZJQ1JsNCtQcHd3cFhj?= =?utf-8?B?c2Zwd1REcXZQNTJFbzh6REZtYWpyV1R1cm5iT1prS1Y4N09YYXhMeUx6Rm9u?= =?utf-8?B?RzltR2FDZ2hMRFdZZVd5Smh5TVI3aGNYTWc2UVd1aXR1djVJbWpycjFKWTNC?= =?utf-8?B?TlZmeHg4dEVQTHAvL1ZQV1p6VWJ3STlRMUJmUVpWcTRSYlhvTGtKRFBHUERm?= =?utf-8?B?Sitqc01MdktTSnY4Y0p0LysxOG5ScjFNRnJBaWVwNmxXUWlITysrUG5ocjlY?= =?utf-8?B?dFY4eHFQVjk1ZFJ4SDA1UW1VMUtYZTA4QnJLQzhYVktKRzhLQ2tVWkxJa3kr?= =?utf-8?B?Y0lvWEFIMmw2a0lpZDN3bGhqMVl1VkNNUHRpQ1FLU0Y5Z0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2e9hRTy3ymg3sA5OLBtC+fcriJWVSax838po/4EEoAGpO5WHNzINY+KA3U7GmAKzKnd59cJSIycddAPdTJ42GTnMhO1q7X/24no23mWvnDwcsbUetLZpJkx6mNggVABWN0gNzaec5az/Jw2v6yS9zZVPqm2gKrVVGgx4xo4eki5TyRaDAYq3UEm5DPh8g1H4Q6eMF8CrB/aGjWH4WUbOVS1gZ+q+Si+O12kO3mSp0XaClN9 SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1;DM5PR12MB1306;20:CfSDK6Z3iBUQayFf2iEa38bAO5/xzwXsbs4I0UXDtvUv5gNgHQCyUSWwIuOHm4u/FTMg+AxTvgPthroFWexrNkprX2Jz1GGqgSgAoMlumZgSSxNePNA8tzXZ2ShqH4esFLUftx50PWQc+k2rk0QxOMdUjbZKoBCRzdcNZv9w24tZab3nal+evZI8VTKpMj5DjteQvC2yxyCcYpfsZ8oEynVZh9muYdyM+7dh9L2FSEsWZhut/QWUpYMd9ad/4TFJ X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Dec 2017 18:06:52.9464 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: d8ca3c43-2404-4e54-0a64-08d5470b491f X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1306 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1307 Lines: 45 Am 19.12.2017 um 15:52 schrieb Konrad Rzeszutek Wilk: > On December 19, 2017 9:32:55 AM EST, "Christian König" wrote: >> TTM tries to allocate coherent memory in chunks of 2MB first to improve >> TLB efficiency and falls back to allocating 4K pages if that fails. >> >> Suppress the warning when the 2MB allocations fails since there is a >> valid fall back path. >> >> Signed-off-by: Christian König > Is there an Reported by or such needed? Sorry my fault not to include that. Reported-by: Mike Galbraith . >> --- >> lib/swiotlb.c | 8 +++++--- >> 1 file changed, 5 insertions(+), 3 deletions(-) >> >> diff --git a/lib/swiotlb.c b/lib/swiotlb.c >> index cea19aaf303c..63a44fb29ce6 100644 >> --- a/lib/swiotlb.c >> +++ b/lib/swiotlb.c >> @@ -769,9 +769,11 @@ swiotlb_alloc_coherent(struct device *hwdev, >> size_t size, >> return ret; >> >> err_warn: >> - pr_warn("swiotlb: coherent allocation failed for device %s >> size=%zu\n", >> - dev_name(hwdev), size); >> - dump_stack(); >> + if (!(flags & __GFP_NOWARN)) { >> + pr_warn("swiotlb: coherent allocation failed for device %s >> size=%zu\n", >> + dev_name(hwdev), size); >> + dump_stack(); >> + } > Ok, let me queue it up. Thanks, Christian. >> return NULL; >> }