From patchwork Sun Jan 31 00:55:09 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pavel Roskin X-Patchwork-Id: 75937 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o0V0tRR4002124 for ; Sun, 31 Jan 2010 00:55:27 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753504Ab0AaAzX (ORCPT ); Sat, 30 Jan 2010 19:55:23 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753427Ab0AaAzX (ORCPT ); Sat, 30 Jan 2010 19:55:23 -0500 Received: from c60.cesmail.net ([216.154.195.49]:35257 "EHLO c60.cesmail.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932155Ab0AaAzX (ORCPT ); Sat, 30 Jan 2010 19:55:23 -0500 Received: from unknown (HELO smtprelay1.cesmail.net) ([192.168.1.111]) by c60.cesmail.net with ESMTP; 30 Jan 2010 19:55:22 -0500 Received: from mj.roinet.com (unknown [72.92.88.10]) by smtprelay1.cesmail.net (Postfix) with ESMTPSA id 2CC4834C69; Sat, 30 Jan 2010 19:55:16 -0500 (EST) Subject: [PATCH 1/2] mac80211: reduce stack usage in sta_ht_capa_read() To: linux-wireless@vger.kernel.org, "John W. Linville" From: Pavel Roskin Date: Sat, 30 Jan 2010 19:55:09 -0500 Message-ID: <20100131005509.22303.74752.stgit@mj.roinet.com> User-Agent: StGit/0.15-22-gda30 MIME-Version: 1.0 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Sun, 31 Jan 2010 00:55:27 +0000 (UTC) diff --git a/net/mac80211/debugfs_sta.c b/net/mac80211/debugfs_sta.c index 0d4a759..84865e7 100644 --- a/net/mac80211/debugfs_sta.c +++ b/net/mac80211/debugfs_sta.c @@ -165,7 +165,7 @@ static ssize_t sta_ht_capa_read(struct file *file, char __user *userbuf, if (_cond) \ p += scnprintf(p, sizeof(buf)+buf-p, "\t" _str "\n"); \ } while (0) - char buf[1024], *p = buf; + char buf[512], *p = buf; int i; struct sta_info *sta = file->private_data; struct ieee80211_sta_ht_cap *htc = &sta->sta.ht_cap;