Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp5296103pxj; Wed, 26 May 2021 07:25:36 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwlezZiQzsBj4DZf4aMGn3LaqrkZqCc3QmUhj4KntIrASGzAEuRJ5M1M9I/dKeVTwBt/7AE X-Received: by 2002:a17:906:ad1:: with SMTP id z17mr21246330ejf.150.1622039136241; Wed, 26 May 2021 07:25:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622039136; cv=none; d=google.com; s=arc-20160816; b=dyG7UUuIJan3EmIHNPygckCMWus5NuDDloxFyGLOLHWrZ3nLIQZqIyOqntV4VOhBLs qD2uKBTBCSKMj3GqURqxg+yc0w8RGQc6g/4gwCMdzE7EuCRhhk+hceYvVI71riGTqqld ztwCBuxQFX+CDLGx303HO7xnh5dqF/TNFfOoGnPeJw0Ubo5wxkx0Ex4ydSJY2IRp6RIY XfYcvTYGdU9360p6+9HOqPatN/NynJGW3BQjsR0XXCx+ZNnwjfhviPNAjloSS0YkGwge oPzmMPGvh8T2M+XarVAdaonc2yye3nX6DUH5rDaeMDqCFsYk3CIWN4D7tpK1zK/6f2zM Kz1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=PlH6e0RLANPN4C0rhH8q8pjH5iIcPQTNlpL2Syq/QQk=; b=fManaVKPC6F7L5AnQoXaJkjUsUVw4swtOiD9CIrVNCmv98qS5pPeWlcPwOYzZp2cFA nwPp+K4AMLwQ8F8C8899SerInGzkXOxTOSZ/fEqL1eb24oG4nc9NHwxmTt7xLN+g8oM8 +NqOViRjFfplH6t44AnZBa6+57jMnfflBV+XH8cmXCjSMaRxb6f553S0MQU2igmIWZ3i GQaUn2cyVXqjVVmxPWap7gjeQYrPhRi7mloAQsHr/TFgY+gFypgzZbZdazPRsz+J8hVd zDMZqhbMHISqG/DH83M2RFDwtc57ujK6o705RdYEdw/n3oBjja3iH4La0bHHvQ0VqHYw jfQw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=A0v2QFrC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v7si23193202edj.318.2021.05.26.07.25.11; Wed, 26 May 2021 07:25:36 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=A0v2QFrC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234096AbhEZOXA (ORCPT + 99 others); Wed, 26 May 2021 10:23:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59308 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234591AbhEZOW7 (ORCPT ); Wed, 26 May 2021 10:22:59 -0400 Received: from mail-lf1-x12f.google.com (mail-lf1-x12f.google.com [IPv6:2a00:1450:4864:20::12f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C36B0C061574; Wed, 26 May 2021 07:21:25 -0700 (PDT) Received: by mail-lf1-x12f.google.com with SMTP id b26so2805202lfq.4; Wed, 26 May 2021 07:21:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=PlH6e0RLANPN4C0rhH8q8pjH5iIcPQTNlpL2Syq/QQk=; b=A0v2QFrC80dq4lVWyNcodXJSoqneMe/xOXe2cjcAXmUhe8FbPVCg7t4m4YQ/xjQgWl 5YQ17KGwsxBw82MXESua6U9fJ+uvyH/kWlAeoioYzb3LPyXI6xP+D4Yf+30sSM2AHF0I VwwOq1a1P91/jdl3TNSKtYEmUR+MCPyMIbL3M1HWFmqsghYTqHwdlTllMyYZmi6PR50t TiM8QECWS9wKmMdhRe4D4kowDI9KGzsYM9IxKejVFWGAJFm8BXFv6AmSDZ4x/yOxia3Z K05uOjXi1pB2NfEmVMc6EBuych+fFT6s0T5ulaVSLFmWHYzY1EmDQz3XcJR+Izn63Cwz wepQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=PlH6e0RLANPN4C0rhH8q8pjH5iIcPQTNlpL2Syq/QQk=; b=Vj1rFqLXMWu2HbgJYVfOM643vzfL3Stv4q3PKNpAxY2KBgZQvvGqLLGHbPuplF4dEt rFkQ+SOMow+XBu5p6ydM2bomxFClEe5cYUPfVOil5zr9IRjjexdr5J4uu7NURSJYRydw v6mX6+Ei3hoIXxv9tva0nGVM+3HMQC7iU7KvE3Y4gOoMsv6tVhuTN1T/SJi06DN2z0Qq aK25krrnufXD+ZOoDJR9BDy1IZLF6eLVEt+AylBS564f2zA5Otl8A9nYR6SxzMX4ByD3 W7U9SFqjoQbL6YDDbJOnl1db6rK931+hQcUzx1aMKm6aRbnYo0CJBc5ckYKCxGDIUDl+ 2DHg== X-Gm-Message-State: AOAM531IzgTpTt0oSmxttE+mhIvx88RPUA/tADsqlcHl0rGWrk2G5gld JplBSeGnUKcuReDhzrtG/bUolPbJexY= X-Received: by 2002:a05:6512:b17:: with SMTP id w23mr2241433lfu.133.1622038883841; Wed, 26 May 2021 07:21:23 -0700 (PDT) Received: from [192.168.1.102] ([178.176.73.49]) by smtp.gmail.com with ESMTPSA id d15sm2040840lfa.137.2021.05.26.07.21.23 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 26 May 2021 07:21:23 -0700 (PDT) Subject: Re: [PATCH 21/24] usb: host: xhci: Move array of structs from the stack onto the heap To: Lee Jones Cc: linux-kernel@vger.kernel.org, Mathias Nyman , Greg Kroah-Hartman , linux-usb@vger.kernel.org References: <20210526130037.856068-1-lee.jones@linaro.org> <20210526130037.856068-22-lee.jones@linaro.org> From: Sergei Shtylyov Message-ID: <8551978f-27b0-767e-f92b-e96ab3064b33@gmail.com> Date: Wed, 26 May 2021 17:21:22 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.10.1 MIME-Version: 1.0 In-Reply-To: <20210526130037.856068-22-lee.jones@linaro.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/26/21 4:00 PM, Lee Jones wrote: > Fixes the following W=1 kernel build warning(s): > > drivers/usb/host/xhci.c: In function ‘xhci_reserve_bandwidth’: > drivers/usb/host/xhci.c:2859:1: warning: the frame size of 1032 bytes is larger than 1024 bytes [-Wframe-larger-than=] > > Cc: Mathias Nyman > Cc: Greg Kroah-Hartman > Cc: linux-usb@vger.kernel.org > Signed-off-by: Lee Jones > --- > drivers/usb/host/xhci.c | 8 +++++++- > 1 file changed, 7 insertions(+), 1 deletion(-) > > diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c > index ac2a7d4288883..40ce4b4eb12ad 100644 > --- a/drivers/usb/host/xhci.c > +++ b/drivers/usb/host/xhci.c [...] > @@ -2788,6 +2788,10 @@ static int xhci_reserve_bandwidth(struct xhci_hcd *xhci, > return -ENOMEM; > } > > + ep_bw_info = kzalloc(sizeof(*ep_bw_info) * 31, GFP_KERNEL); Why not kcalloc()? [...] MBR, Sergei