From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) (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 3487BEACD for ; Thu, 12 Feb 2026 11:43:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=205.220.168.131 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770896603; cv=none; b=CogL2eYo8RHHvfuoV3V5MAAMgZ71xPkpxf/6nus8RwNoolX5G0CMtV8nzHXjUzjAWn3mGrWZlIqsiCOk3sb2+eMa0ZnCLBqXREgKLIv72h4tOTGuGWNhHtMUvxrbJX154kLuGu03daIjyMD1KNpXqbQK9XW8nj3R6wZgzu6Di7w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1770896603; c=relaxed/simple; bh=/r6h55ep8vDaYXzMjypF8LP0CmRspeweiNim/QcWd1M=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=ldlDtNxx8tYe9YN/7458bxlaO7p2EpSq3XjDEdJ9sQggb6ZQgVjaTr1glCOSL6g2LfUzvSaTvo7pnGEMv8aIIS/Kct1AYX3YkaIpKCBQqTHRQX3g79Zzm/0Sbg6wcRT9ycphd3T2odq90sNf/PcnXz8i73AlQRopYMp9ZKbKSls= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com; spf=pass smtp.mailfrom=oss.qualcomm.com; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b=dlu/whk/; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b=MwMyOTPN; arc=none smtp.client-ip=205.220.168.131 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oss.qualcomm.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=qualcomm.com header.i=@qualcomm.com header.b="dlu/whk/"; dkim=pass (2048-bit key) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="MwMyOTPN" Received: from pps.filterd (m0279862.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 61CAP2Do3888000 for ; Thu, 12 Feb 2026 11:43:20 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= rE3HZZJCFRgTxa0EFA3Pcd/g06oH1wjDmN+ZLl7iKOA=; b=dlu/whk/+uMdlZ23 QeDrHnhoPd10GnR7KCJfZixyxdsSgHh7KL2yny0CYdGSEX0zULPT3YJXYNuuFIco w9Bh/N3/yyZ2BF3syvMCiT+fbgtSZa6rQ5P1wn6XUD4nyndZFXBL9EhVkYvPSf6t 3SA3wEVV9QRypbAYRE/0CRVChWo8GkY9ZT22DISG4mBzMDxcUWDPGMKVpJ7H4snF OlaJGWrjoJuvUe60yp9tDr9prBQE5a0+FwPRBlhD90QKovCioj9T6IRzjV1RYQiX bgEv+AWci/ShXS1WyaFpxKrrnygAcQb26VTXRnMy1cdfg3sA+K0N/0my/l9+QwRc G2EWOw== Received: from mail-qk1-f197.google.com (mail-qk1-f197.google.com [209.85.222.197]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4c90wjae5c-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Thu, 12 Feb 2026 11:43:20 +0000 (GMT) Received: by mail-qk1-f197.google.com with SMTP id af79cd13be357-8c52de12a65so150118585a.2 for ; Thu, 12 Feb 2026 03:43:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1770896599; x=1771501399; 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=rE3HZZJCFRgTxa0EFA3Pcd/g06oH1wjDmN+ZLl7iKOA=; b=MwMyOTPNdpYHuyR7lrYCCdptZu83vu0ROnfdRRWoLLsdlsVUdT6fLDU/3T/gxblsed VQMTPAS4Id26ZKdN4euquBTk28FUyPZ/V2OdSkZBgftUUtcqFakW8qIxhPdnjpK+jiGA ph98VUK7TV0EYZNuriSZdyJKJ/sQct228IcVQQlMWzvSKfW9dbDG+FH1o+9A/R3MNSfJ A/1/03KAtYeIopF/KhSFkEFfC2YCWLBBxxKXaGds/svgNGAWBbL4B9xwxQq+KA5dFvxi tHfNcMh6TrpMTg3k7XZ+qz/8r8Bm10wlolYkmcXwjSnEsDooF/N7ceiurxJcb5pbg0Ww JbGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1770896599; x=1771501399; 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=rE3HZZJCFRgTxa0EFA3Pcd/g06oH1wjDmN+ZLl7iKOA=; b=hFMsAJPgqAOg4334GBkYUNl7i5m7Jbl8oORW3gmrYAdfjxACV2mj+ryYTh6OIuKl6R duFG9FZNnIjVIM99dQ4KFXnWs96H3uj2QcbeC4SfVcX7UUVxEafld1KmyL6RLrbCIZ6o rB3TsH/0geE/FsXjP7GhiDkGW5hAwTMwncR9z7CDjS/i8FNGml32cV/mK4NlO9NsV/VV V49U1a/AXhzcocnKkpYXiFX8X3gU98ZHDN6LeYyGrcKMuvswq8lC/9s+7RpS2CkdJQq2 koBKbBCpwkG8I/O4wKCj4hqLAUl111B1P9MTzhCjDFihDgmqvX27A1f3CAVh0Y4NqoRl ycIg== X-Forwarded-Encrypted: i=1; AJvYcCVccSGw/CEpVX5KUAYngWDka/JPWI3TASueJxQkne4SHHVgd0LdIpn54bvUlixo734zfMu+xu28/F8zhK0=@vger.kernel.org X-Gm-Message-State: AOJu0YwzDLWx8AuzEPEZuF7IueJSwIE7ApZQUG0a80Ng4ys8ZltNwilx O9H/hMioFDQlCmE/yNl5kRZe0ZaEoF/AzTtcF9DAjSUR7RLhjqUgIrOV2/59hoethp2UpLZDpAL qGC0ZUPuiaTEmhlKa7S1b0uVYcEtDdIJEy9oU+LiC31sJvpFd2+5FgW5viqk6uGr3Bg947G68ob I= X-Gm-Gg: AZuq6aJExCl42VGMnmrUf0KauPUcIo2o0ov624sar0EyFi4NnAohtMHgXzKMZ2su92f NqccxGGW/JgP1nz1ge0JGmyxhbijBMMj3FaiY9E9t/IBAyrG+5bKgbkKzcap0LilrfXoURF8oKj RFnrbuRQ4IzQtwqqdjthLojd/Ytsj2sDgQ78Pqq6NrbWYjo/9nDlKQ6qcYE3zvJmLg/itlQPhCi jOIDMZGZb+RFBE2FgY3n0xWZWERGosavgLBkDIYdKbZLDYh5UVppB9Ss/OhKsz8wLQ8XfN7kpqh qSfhVwdSt1LJuHgYlM9a0+UPtks4OMiWdnCb2zniP6pZtVBkkPBWxF2RAyh4cIreR8LAXnNMctL NdfooKLK4G7cfjpC+d9j9aKa/IJpBzzOC2gRT0awpnEdt3dHOWjr/B+6CdBGYZWi6oBvD+gfZ8B fL6yM= X-Received: by 2002:a05:620a:46a1:b0:8c5:305e:ea16 with SMTP id af79cd13be357-8cb3315b4bamr224365385a.8.1770896599396; Thu, 12 Feb 2026 03:43:19 -0800 (PST) X-Received: by 2002:a05:620a:46a1:b0:8c5:305e:ea16 with SMTP id af79cd13be357-8cb3315b4bamr224362585a.8.1770896598867; Thu, 12 Feb 2026 03:43:18 -0800 (PST) Received: from [192.168.119.254] (078088045245.garwolin.vectranet.pl. [78.88.45.245]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-b8f97e2e705sm36671566b.61.2026.02.12.03.43.17 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 12 Feb 2026 03:43:18 -0800 (PST) Message-ID: Date: Thu, 12 Feb 2026 12:43:16 +0100 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 2/2] media: iris: Enable Gen2 HFI on SC7280 To: Dikshita Agarwal , Dmitry Baryshkov Cc: Vikash Garodia , Abhinav Kumar , Bryan O'Donoghue , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org References: <20260209-iris_sc7280_gen2_support-v1-0-390000a4fa39@oss.qualcomm.com> <20260209-iris_sc7280_gen2_support-v1-2-390000a4fa39@oss.qualcomm.com> <0da582a6-5bba-4450-99ec-cf57b67915e6@oss.qualcomm.com> <0a324898-092b-3e44-c35c-15de20b50f40@oss.qualcomm.com> <2uih6xdzarkwnvhlhv5kznmdwo4jorqvsrb7xxrxgr6vprx3ey@4kx45k5i3c4y> <6b9042c8-767e-0fdb-9012-f3790899509e@oss.qualcomm.com> Content-Language: en-US From: Konrad Dybcio In-Reply-To: <6b9042c8-767e-0fdb-9012-f3790899509e@oss.qualcomm.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Authority-Analysis: v=2.4 cv=DtlbOW/+ c=1 sm=1 tr=0 ts=698dbcd8 cx=c_pps a=50t2pK5VMbmlHzFWWp8p/g==:117 a=FpWmc02/iXfjRdCD7H54yg==:17 a=IkcTkHD0fZMA:10 a=HzLeVaNsDn8A:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=Mpw57Om8IfrbqaoTuvik:22 a=GgsMoib0sEa3-_RKJdDe:22 a=EUspDBNiAAAA:8 a=_qvAbxjOzlPTnpeXTmgA:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=IoWCM6iH3mJn3m4BftBB:22 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwMjEyMDA4NyBTYWx0ZWRfX8PrMAZA8uIqb OCiivRGN5pAZ1A52aA0avsZzvXllVkBAcXulSlPpsDklsDD9EwHNLmPqbQ6P/UqhKe6FNA6OhsJ 8/rBrcDJ3eils4OC8xq+rWOblgzkUsQ1wwUIprUOhfnKlJzReM2KEhL66x7JRUuqCZBEoE+nZBY 5CD1Ses/svVnNer3kCX/e0cramBsZCK7Za0mSloFt/LcKJxIurcu0aCjySTxDro6l+/oHTpDbvv vglAPyHZiAQkmb9Y5pkgUEleHKUkp4b3zduf/TuhF0UKWDiMJAuom/54Or1b6KDeHM8d0dPYufm o1Phsp6elL9VVUYZXV9MY0iRpjH7u8iPL1ugvAy1w5oaAvI5pdhY1g+aH1KVbNEDC6Qt2JgvqRM 0VfLpTK775hTFlgbLL8mvq7idQ8JVHbPU9xQh9OHXM6160UFdRvMZDvYpZkhXpLB6m6pnSCeOC4 hxjLwX6APsCT768bQzA== X-Proofpoint-ORIG-GUID: u143K8Jca7Nl56eY2vhaMTv4B0U1dVA6 X-Proofpoint-GUID: u143K8Jca7Nl56eY2vhaMTv4B0U1dVA6 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1121,Hydra:6.1.51,FMLib:17.12.100.49 definitions=2026-02-12_03,2026-02-11_04,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 spamscore=0 suspectscore=0 impostorscore=0 adultscore=0 lowpriorityscore=0 clxscore=1015 bulkscore=0 malwarescore=0 phishscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2601150000 definitions=main-2602120087 On 2/12/26 12:16 PM, Dikshita Agarwal wrote: > > > On 2/9/2026 6:05 PM, Dmitry Baryshkov wrote: >> On Mon, Feb 09, 2026 at 05:04:48PM +0530, Dikshita Agarwal wrote: >>> >>> >>> On 2/9/2026 3:32 PM, Konrad Dybcio wrote: >>>> On 2/9/26 10:45 AM, Dikshita Agarwal wrote: >>>>> SC7280 supports both Gen1 and Gen2 HFI firmware. The driver continues to >>>>> use Gen1 by default, but boards that intend to use Gen2 firmware can >>>>> opt‑in by specifying a Gen2 image through the Device Tree >>>>> 'firmware-name' property. >>>>> >>>>> Based on this property and the availability of the referenced >>>>> firmware binary, the driver selects the appropriate HFI generation and >>>>> updates its platform data accordingly. Boards that do not >>>>> specify a Gen2 firmware, or where the firmware is not present, >>>>> automatically fall back to Gen1. >>>>> >>>>> Signed-off-by: Dikshita Agarwal >>>>> --- [...] >>> To avoid accidental matches, I can switch to an exact filename match >>> instead. That way, only the specific Gen2 image (for example >>> "qcom/vpu/vpu20_p1_gen2.mbn") will trigger the Gen2 path, and boards that >> >> How do you detect that for the OEM-signed firmware, which can have >> random name? >> >>> want to use Gen2 can opt in by naming the firmware accordingly. > > I Explored on suggested alternative approaches and seeing some limitation > with the both of them: > > 1. Detecting Gen1/Gen2 by scanning the firmware blob (fw->data) > It is possible to parse QC_IMAGE_VERSION_STRING from the .mbn and extract > the version string. The issues with this approach : > > - the version string has no explicit marker that identifies Gen1 vs Gen2. > > - This prefix is not a formal ABI, and it is not consistent across SoCs. > Each SoC family uses different naming patterns in the version string. > > Example : For SC7280 Gen1 we currently see: > QC_IMAGE_VERSION_STRING=video-firmware.1.0- while SM8250 has > QC_IMAGE_VERSION_STRING=VIDEO.VPU.1.0-00119-<> > > So the driver would need SoC‑specific string‑matching rules, which is hard > to maintain if we are looking for a design to address all available SOCs. The only SoC with such distinction today is kodiak. So we can simply check: if (kodiak && strstr(fw->data, "VIDEO.VPU.1.0.") hfi = gen2; Can we agree that VIDEO.VPU.x firmwares are hfigen2? If so, problem also solved for <=8450 Konrad