Received: by 2002:a89:2d5:0:b0:1ef:f8eb:5d24 with SMTP id d21csp117997lqs; Sun, 17 Mar 2024 13:21:08 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVSqut9IDR7Jwb2TtqFo29MOq1nruQHV786UPGNq64dg8wRIhBnNaunbswee14LhKIDLBjzmP8sgb3OOJeFOtDMp7A8SRirqPG9rl8efA== X-Google-Smtp-Source: AGHT+IEd6Lm2KEed/gBe9Mfr2EYxXivhJcntvdTT2/cTuNkyPGcSo0gNrOO6HJNvvPXZ8k1XHOYw X-Received: by 2002:a05:6a21:181:b0:1a3:26b5:c7bf with SMTP id le1-20020a056a21018100b001a326b5c7bfmr12011177pzb.47.1710706867806; Sun, 17 Mar 2024 13:21:07 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710706867; cv=pass; d=google.com; s=arc-20160816; b=bWPecW+gb1V4hyV8pQ3MejCf+l/z2sKA78g/gxdH+GxJgBHgzukeRyImS6qRtiUSYG Whm9BGmYBSrryYy8ATG+NNzCbJw7MIszuVjqGFgt9Q1fr6q4QVms6r/8oUGP/nEcCXvl 108h46ONQGVJ8xX2o2D42KpSS/77dVoClOSaD7795dLcbG9Qw9ZAq8d53IY9kyhDJtz6 caYl1bX+BHuT6Ru29QuGK9qafLNvAU4WazG2Q1br7Grsfdf/QboQdd3eY+BjyXFIZl5Q Mshkp/burSop6n2KOCbyT47r3n4LKWui9FF8p/krYytmCVzlAbYImR/uOXpZGr6wJLSc uw3w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:subject:cc:to:from:date:references :in-reply-to:message-id:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:user-agent:feedback-id:dkim-signature :dkim-signature; bh=6HrRUHpYXtmNtwn+NXIkI2LhSUVC7t5pMaTnPTvJqzA=; fh=D6HWhpL5I4Mlq7ZScskd1BWCFxc4ZZTkKRJdQNabutI=; b=RL6IippxBnYIbY5kBIZVPIMRfcKQrXYf6BbW+nQpx9atcV3kuqPIdrHBx6eb3NXpTB IwE+VU5zzsCBEbax5ZaG57vo9I6BRDMxO1h3r5YTfrS+Jw+ikmIOxfQh6b70c0Slfpsv 3krfic4RYDdu2lE0xaOTe1Oa9sN5pqkjad0Z5iBjign8a7rR+2P2z8kUAFr+xP318OVU ucNQTAkFZgIueBJ7v6MNHFkZ1TOqcEj90ZnD5bmZ/1+n8Nsn+muqs2TL6J8rfjfL7Hkw 2OBDZyB7POjEAOcvGYp8P4haVzSSTsD4w556FmYRa5d11O/Q2MgJwkjHZ59IczBNG9tF iIxw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@arndb.de header.s=fm1 header.b="C/uVcQgP"; dkim=pass header.i=@messagingengine.com header.s=fm2 header.b=hV0P8wI+; arc=pass (i=1 spf=pass spfdomain=arndb.de dkim=pass dkdomain=arndb.de dkim=pass dkdomain=messagingengine.com dmarc=pass fromdomain=arndb.de); spf=pass (google.com: domain of linux-kernel+bounces-105547-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-105547-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=arndb.de Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id q19-20020a056a00085300b006e72289a0ecsi1308806pfk.177.2024.03.17.13.21.07 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 17 Mar 2024 13:21:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-105547-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@arndb.de header.s=fm1 header.b="C/uVcQgP"; dkim=pass header.i=@messagingengine.com header.s=fm2 header.b=hV0P8wI+; arc=pass (i=1 spf=pass spfdomain=arndb.de dkim=pass dkdomain=arndb.de dkim=pass dkdomain=messagingengine.com dmarc=pass fromdomain=arndb.de); spf=pass (google.com: domain of linux-kernel+bounces-105547-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-105547-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=arndb.de Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 6857F28149A for ; Sun, 17 Mar 2024 20:21:07 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 39620200C1; Sun, 17 Mar 2024 20:21:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=arndb.de header.i=@arndb.de header.b="C/uVcQgP"; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="hV0P8wI+" Received: from wfout8-smtp.messagingengine.com (wfout8-smtp.messagingengine.com [64.147.123.151]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 310761EB2D for ; Sun, 17 Mar 2024 20:20:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=64.147.123.151 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710706860; cv=none; b=E+IA4TR477/7BAD7wpt2tmnyk4rhIP7aInJPVl4YOlk6peiLt5cVVXZiUFmCeDnHrayiuu7HB6Nblf6c0DVBe8pkEKW7fFpXbtHcz+6We3I+wsG4lfznCdWGkX3Z2hnhg5HrhoYDUNvgn+a4KM1K/G1rFq5Fy/BUxn4le3+ZrJU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710706860; c=relaxed/simple; bh=/1v7Vj6mpZndRJ2eX6+FUyOOJ7RtQ+j9vPkLALQZgAM=; h=MIME-Version:Message-Id:In-Reply-To:References:Date:From:To:Cc: Subject:Content-Type; b=j49fovNFbcBSX9QC7OoxENQ2EXr//mXcWfhEpFtWkFPQpDMkmrr/COvOrbTCnn/WkZEqOJGc2rZKb4Oqpk7bdgdFgDuPHzBetsdrF3gQmbNLdU68Daygupnp2xYhL4GtxwYvI5Q08WYJyx6P3A2VnLbQf2FVeDpdn6RbPp5MWVY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arndb.de; spf=pass smtp.mailfrom=arndb.de; dkim=pass (2048-bit key) header.d=arndb.de header.i=@arndb.de header.b=C/uVcQgP; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b=hV0P8wI+; arc=none smtp.client-ip=64.147.123.151 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arndb.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arndb.de Received: from compute5.internal (compute5.nyi.internal [10.202.2.45]) by mailfout.west.internal (Postfix) with ESMTP id 9B93F1C000BF; Sun, 17 Mar 2024 16:20:56 -0400 (EDT) Received: from imap51 ([10.202.2.101]) by compute5.internal (MEProxy); Sun, 17 Mar 2024 16:20:57 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=arndb.de; h=cc :cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm1; t=1710706856; x=1710793256; bh=6HrRUHpYXtmNtwn+NXIkI2LhSUVC7t5pMaTnPTvJqzA=; b= C/uVcQgPeNZzFNajaT9i48G1eVpZV83W8eXFp4qaMkEN0pU+66bys2zs3JAtoPDa ulKWcUxR4UD2LkXXeeSgoCqeJng2Mf1hqh3uKDDh0uwDjJHsP7WO3FFpF4hNOGaj /cpcjVahuc63MWtMeqdJCzNLvb9STt7tzly29kE2H8ePu0VWyhZlg3Ef5ziv37aS EbVNiPfxjl3Xk7cKCRkaE8Fhxs2x0OQ9yfhsL97D1NzN47nzhsphok5vA62mTDk3 KSh+JjYUN+BTlCjNjXLx0b7UmmvfUINbSg2uAGq2Rgt2Q4IhSL67elkrUlPnBT6F BXSezF6ymmuxtAsMJuCHOg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t=1710706856; x= 1710793256; bh=6HrRUHpYXtmNtwn+NXIkI2LhSUVC7t5pMaTnPTvJqzA=; b=h V0P8wI+qYNmmHPjirwWAC/ncxDmy1f6OGNfjSfg/8K/JPM2qOI2ru/t/pPcglaGc lOiWamZTrKoOsliVFgoTMmvx5jRpIf3NclgRy/P5K7ODamjaUqkP2ikv6NCUMuVl SAw31wIY1ojr9XTkcdJAgDiyhWKojeAIupdTZmz0ekSORKBZddHn2vrrFswlumfB i3cxcod71/VW+oJrGdE8MigzdyiBG+rEKFKsuBpkHS4/AsEoqGKJ6vpIa3Rb4Clt TrYaKx35+BdZH9TXs9/McfT2IufFWlZe0U/7uU8wEKowVLMjrF5ZkZaq6jcFF0hw sVkVtS7oh6fKVNfLEENjw== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrkeehgdduudefucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepofgfggfkjghffffhvfevufgtgfesthhqredtreerjeenucfhrhhomhepfdet rhhnugcuuegvrhhgmhgrnhhnfdcuoegrrhhnugesrghrnhgusgdruggvqeenucggtffrrg htthgvrhhnpeegfeejhedvledvffeijeeijeeivddvhfeliedvleevheejleetgedukedt gfejveenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpe grrhhnugesrghrnhgusgdruggv X-ME-Proxy: Feedback-ID: i56a14606:Fastmail Received: by mailuser.nyi.internal (Postfix, from userid 501) id C1B81B6008D; Sun, 17 Mar 2024 16:20:55 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface User-Agent: Cyrus-JMAP/3.11.0-alpha0-300-gdee1775a43-fm-20240315.001-gdee1775a Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Message-Id: <5716d138-ace0-4621-ab34-118610255207@app.fastmail.com> In-Reply-To: <6c772d15-d249-4175-93f4-ca523006129b@gmail.com> References: <6dc14151-e71e-4118-826d-3ca5c8ee907f@gmail.com> <6c772d15-d249-4175-93f4-ca523006129b@gmail.com> Date: Sun, 17 Mar 2024 21:20:34 +0100 From: "Arnd Bergmann" To: "Philipp Hortmann" , "Dan Carpenter" , "Lee Jones" Cc: "Greg Kroah-Hartman" , linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org, "Larry Finger" , "Johannes Berg" , "Kalle Valo" Subject: Re: [RFC] staging: wlan-ng: Driver broken since kernel 5.15 Content-Type: text/plain;charset=utf-8 Content-Transfer-Encoding: quoted-printable On Sun, Mar 17, 2024, at 21:07, Philipp Hortmann wrote: > On 3/11/24 08:04, Dan Carpenter wrote: >> On Sat, Mar 09, 2024 at 11:09:24PM +0100, Philipp Hortmann wrote: > You are right with the statement that it is this commit. > commit ea82ff749587807fa48e3277c977ff3cec266f25 (HEAD) > Author: Lee Jones > Date: Wed Apr 14 19:10:39 2021 +0100 > > staging: wlan-ng: cfg80211: Move large struct onto the heap > > Fixes the following W=3D1 kernel build warning(s): > > drivers/staging/wlan-ng/cfg80211.c: In function =E2=80=98prism2_= scan=E2=80=99: > drivers/staging/wlan-ng/cfg80211.c:388:1: warning: the frame siz= e=20 > of 1296 bytes is larger than 1024 bytes [-Wframe-larger-than=3D] > > But It is not depending on the line you pointed to. Right, the kzalloc() already clears the data, so the memset is not needed. > I need another week to look into this. I'm fairly sure this fixes the bug, the problem here was that the cast to (u8 *) hides the incorrect conversion: diff --git a/drivers/staging/wlan-ng/cfg80211.c b/drivers/staging/wlan-n= g/cfg80211.c index 471bb310176f..9d6a2dd35ba9 100644 --- a/drivers/staging/wlan-ng/cfg80211.c +++ b/drivers/staging/wlan-ng/cfg80211.c @@ -350,7 +350,7 @@ static int prism2_scan(struct wiphy *wiphy, msg2->msgcode =3D DIDMSG_DOT11REQ_SCAN_RESULTS; msg2->bssindex.data =3D i; =20 - result =3D p80211req_dorequest(wlandev, (u8 *)&msg2); + result =3D p80211req_dorequest(wlandev, (u8 *)msg2); if ((result !=3D 0) || (msg2->resultcode.data !=3D P80211ENUM_resultcode_success)) { break; Arnd