From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wm1-f44.google.com (mail-wm1-f44.google.com [209.85.128.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6A27D2D9EF4 for ; Wed, 26 Nov 2025 12:11:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.44 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764159071; cv=none; b=Wh759mkvKbwYKdNDz48IQynt54TEXdjxb4hMC8BnRvdb6NNtEkAveoTCqsPe2SXqLLzIy6kfhDGxk0k3ED2IrBFX1pK3SeS+3I8yOsDDD5nwDacaWn/Gb1hJeWcODJCrK1Xvs1QFgEskq9vw/WVu0iCiZAlBO9f5eDEWLzDIsrQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1764159071; c=relaxed/simple; bh=ZHIiqSQuVeRfqZb6xVVGV1b71mRo8p6qabOpMx61sJw=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=foVl+uyiYOiKSfpXeOhfAESOBGjy62DJtVhi9BqZ3F4U2TaEqQKEeCx1D3XBAzOrfXoNLzq87VZD7k+dy7zHcVLRPoYzWO79uiJUM1s880k6wMfJtQ83Ak/8heyQ+9y0X75HSyk7sfZeoth8VYM6UEUyjPo6yudsPw6zT5AlHKE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=xueca91q; arc=none smtp.client-ip=209.85.128.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="xueca91q" Received: by mail-wm1-f44.google.com with SMTP id 5b1f17b1804b1-477b198f4bcso43675845e9.3 for ; Wed, 26 Nov 2025 04:11:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1764159067; x=1764763867; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=c4iRe4aOrrtqdI0rXdKZ+xR4qIxt0v6dXb2WpyvPrtc=; b=xueca91qOwhmUdkJP3f1d3RT85wIEU7fBv0gbyOr1iKMsxPtYa4qTVICy6uoXf84/F QWDli0dGRQm1qPo5rG6H5g7SjRo8is9kOLL/CCVrTDX4CT/im1PqHrvsm4jMMz8sduRm 9gfRV0L8naLU1DKfjOQ+iq4eMMllrb+0oGjVz+RsYJelOuSrDcVcsxHGdwLTY4qKKsi8 Jull4JNCDXMO7/xDXlJwbPnvdkvvlzy35psdPnOPIqWu2b1AoKl47odY15KshyxqS2U7 HGDpavEVKnbe8PBtEn84BuHmvxUVsRgj2oElQrWL9LGLMCb9drrCvOgEboaNDs3SXDa3 bBOA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1764159067; x=1764763867; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-gg:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=c4iRe4aOrrtqdI0rXdKZ+xR4qIxt0v6dXb2WpyvPrtc=; b=ewGBvahqZk1EfRjYR6jh3Gu/75lhkpLMVmPh0u3RsYEgFut0OW8GdULh+tFmPZHF0D Qm/cRKH0zm/8aKXDiZlrTkzLGzxbl1zSqtAOhpcgOwQHZAsyv174heXxf5T7I97K+SY6 ftIZ3p0N6OpIVvXeznBlDmY8UgUyZJb3pXSeESiwGWSz4jt2rdZeINBIVS2eks+P6w8R gcGT51wvVyOGvOWolcWib7TVwTEOEl0Qgb9mf22YDwpXOWaxhd7Vj3Hw9MWmW0GvGchf 9phn0lIPEmrRR6Z6SSO85JAAtm3IGQ38x4NcnMJTGjzRhwuqEgSgpTZz02zrnNR0Oprt mjrw== X-Forwarded-Encrypted: i=1; AJvYcCViVAwfqNaVRciCBkEE6pmZlhuwCWGU+875GLi2Rpzik3UZhZJZdzy8Xmvg9cOdPB3EBbOpwSorax4nTCY=@vger.kernel.org X-Gm-Message-State: AOJu0YzsHkaPtMs7fg1X2W21QfLEWA3DQ/0i+bFGgkZ/nTURt7zoGhBu LFX1u8DB+0iQlMRvO4eM2TocF+p7Zu59TQONAciEJFaTFTh8zcsxgNnLAOcR8N7ZR7w= X-Gm-Gg: ASbGncuYa6Lhlcv3hYpIjxHO9wTz+nJ/f+E0PbxYJBvo1WIU4y2EU0DKhJ0HXfkrD32 rVZ1HbeRwpfiV9AhcPm3rieXBfvOY6vcMQRFLDPiI12hKHI+nzhBGpWMfPd/ueH+XTFiawby49g A0NUleLBlwHx11scWiqthcvbifJUVLDuIJ0DjuuGP7eOnkImaFicMKv5ltDZ3P3+Nq3DbOLjfQk ArM+U3elWxW5U2oJUoeUcH+IE+z0JDATD3smZtjVKI+dOshm3AcWCfSJc58+15Zj40ix2aaZwtj U/DPp7Urybe9+dHvag0jhOSOnCg0XMqoMc3+Hv+ENltogEXy0Cfh3XucFiRvGgA1B5VwkOtlRgQ f+JsK6gahbg0/sfdQkeDG6rStIZQDrUwlMoe+5L+inQTB0TAwNWZNGxPda60NOT/28LndeXG1kb ikMVG7sHX0zxyfkLpq X-Google-Smtp-Source: AGHT+IE0risfP7oMpnR/mh4vl4pRCpmyI7fxXRX57NmC+ibT7kErw26ZlIa+wn3mo0aiLmRAJ7cw4Q== X-Received: by 2002:a05:600c:470d:b0:477:63b5:6f76 with SMTP id 5b1f17b1804b1-477c01d3128mr163153595e9.25.1764159066624; Wed, 26 Nov 2025 04:11:06 -0800 (PST) Received: from [192.168.1.3] ([185.48.77.170]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4790adddb4bsm40718535e9.7.2025.11.26.04.11.05 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 26 Nov 2025 04:11:06 -0800 (PST) Message-ID: Date: Wed, 26 Nov 2025 12:11:05 +0000 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] coresight: etm3x: Fix buffer overwrite in cntr_val_show() To: Leo Yan , Kuan-Wei Chiu Cc: suzuki.poulose@arm.com, mike.leach@linaro.org, alexander.shishkin@linux.intel.com, pratikp@codeaurora.org, mathieu.poirier@linaro.org, gregkh@linuxfoundation.org, jserv@ccns.ncku.edu.tw, marscheng@google.com, ericchancf@google.com, milesjiang@google.com, nickpan@google.com, coresight@lists.linaro.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org References: <20251121002350.1166758-1-visitorckw@gmail.com> <20251126120914.GH724103@e132581.arm.com> Content-Language: en-US From: James Clark In-Reply-To: <20251126120914.GH724103@e132581.arm.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 26/11/2025 12:09 pm, Leo Yan wrote: > On Fri, Nov 21, 2025 at 12:23:50AM +0000, Kuan-Wei Chiu wrote: > > [...] > >> I noticed this issue while browsing the coresight code after attending >> a technical talk on the subject. This code dates back to the initial >> driver submission over 10 years ago, so I was surprised it hadn't been >> caught earlier. Although I cannot perform runtime testing, the logic >> error seems obvious to me, so I still decided to submit this patch. > > I have a question for maintainers. > > The ETMv4 architecture specification shows that ETMv4 was released as > a non-confidential module in May 2013 (with the confidential release > even a year earlier). So ETMv4 has been a public IP for more than 12+ > years, and ETMv3 has been gradually retired since then. > > This fix can still be applied to older kernels, but seems to me that > now might be an appropriate time to consider removing the ETMv3 driver > from the mainline kernel? > > Thanks, > Leo Yeah, if anyone is using it it would be on an old kernel surely?