Received: by 2002:ab2:7a55:0:b0:1f4:4a7d:290d with SMTP id u21csp320135lqp; Thu, 4 Apr 2024 14:22:47 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCU8EHwExLH8/Cv/JA+dvj8RGidDQJm/GAYqJ72zyTEZiFmKq3dRgTGGU+P+GU9u7ILi6ncHQJE/NkhdYtzyHZSBbXHpzYG+Kf1wGmsJ5w== X-Google-Smtp-Source: AGHT+IFAIYq6g3Bx0dt51uk4VSFrOjfeXnnFMqkf9xUH6AhKVNHVzSwWKMfjAjv8Ljs1aHuThdWM X-Received: by 2002:a05:620a:1119:b0:788:32b3:2d4a with SMTP id o25-20020a05620a111900b0078832b32d4amr3688655qkk.17.1712265766813; Thu, 04 Apr 2024 14:22:46 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712265766; cv=pass; d=google.com; s=arc-20160816; b=07GlyhUsB2c8uhxqCGWIoLkmi5wCQFPFZvmxvcZXFTF0llAHerfI8ZvNYuJO0sdJ3G OJ8QK5xyuob6/h4/NpGah7FUz2h4+/r5OoeMhWNuQvm3j/FXQ2wbCba+7Rd4Bjg00bCs OCtWWYv1y9nqqH9rC85e5+PiS6zMOWakvB0h6A4HygeNNQFgqWifqXfdMfmSL2W+xsSp 3P754c5lgtkfR33fbeMc0NisTYlEz2EKqUqC5YRwkVKSRHUNyyaZUFbqp4I8LLj1TX+r MWbGpTzqE67jAVeavId3lRFQ4cjo8dw7Rf/BabzHmmVQRu2RZcpXEaPH35VNzTT69qKS BYJg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=mime-version:list-unsubscribe:list-subscribe:list-id:precedence :user-agent:content-transfer-encoding:autocrypt:references :in-reply-to:date:cc:to:from:subject:message-id:dkim-signature; bh=rg3OgrxCT96ehDsWvlDmAIxCDxg1DhsRLeEA2xqhGms=; fh=P/rNOoO5/c21cS7mhhfYgqMbVCVIou1c8fH4LqAz9Fk=; b=kbsXdhcgIwKWCN/weIhVW5w5DmbD5nXF9tIUSSTWakCFF91fwVGaI22UOezkimoIAt yZeL7988v56uOAVFIf5sbYY6BZKXjQYgiuiLUl52sskzPxKtxgwE71CHUinhwraPZdqo vfbnnlzH9axoPnFh2vWTPnlWrNzVulFYfrGqA52qbY7l0SXZkXwInoyJ34ZRWZ0YTO5a eQ8T72XAOijvmLN+I0BFnam8N5LTh+50tPhiimSUdWUuozzYO1qxk32FuxJBScFoHvx6 ZIU5gnLeHZjhURcgP+pH9x2BTeP97XIvQwHiOd66uJci9rXYvFBXDkaBd65v1UxMrUYp npeg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@ndufresne-ca.20230601.gappssmtp.com header.s=20230601 header.b="f/TMKhGj"; arc=pass (i=1 dkim=pass dkdomain=ndufresne-ca.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-131998-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-131998-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id g10-20020a05620a13ca00b0078830baaa2esi233936qkl.572.2024.04.04.14.22.46 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 04 Apr 2024 14:22:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-131998-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@ndufresne-ca.20230601.gappssmtp.com header.s=20230601 header.b="f/TMKhGj"; arc=pass (i=1 dkim=pass dkdomain=ndufresne-ca.20230601.gappssmtp.com); spf=pass (google.com: domain of linux-kernel+bounces-131998-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-131998-linux.lists.archive=gmail.com@vger.kernel.org" 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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 6F1D91C21572 for ; Thu, 4 Apr 2024 18:56:58 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6589413329B; Thu, 4 Apr 2024 18:56:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=ndufresne-ca.20230601.gappssmtp.com header.i=@ndufresne-ca.20230601.gappssmtp.com header.b="f/TMKhGj" Received: from mail-qk1-f172.google.com (mail-qk1-f172.google.com [209.85.222.172]) (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 0707512D770 for ; Thu, 4 Apr 2024 18:56:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.222.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712257008; cv=none; b=C5hmm6snD5DHASKze6xuGn4gqq6SLkQsiyGaREDP0kqJ7CwxxYyE9tESKz68FlTpVzmp6pvgsKu6f2xmqCOHCAuq5gVgrpGO3VGQi5P/A2qQPYwDohazCab6CkntHDGHLPB3YopG+t1S7VYGGsq4/WqV/2/BfBNu7RZrpPnESGQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712257008; c=relaxed/simple; bh=rg3OgrxCT96ehDsWvlDmAIxCDxg1DhsRLeEA2xqhGms=; h=Message-ID:Subject:From:To:Cc:Date:In-Reply-To:References: Content-Type:MIME-Version; b=HuGqOOExsJpHHwOKiC2wsfXp3Z84mG5KE2rZelFqLpOfvqhO4Fltc24pSBn6OANQHuJGVWYcaorS5PVLpKk1fTyL0GFJiYO496OaQTHOm0Dbe19rY6CD8MatTSB/2MiVDY9A5+ZVBnS3jdfwKOq1mHoyDCjvYyOJv+2A72opfsk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=ndufresne.ca; spf=none smtp.mailfrom=ndufresne.ca; dkim=pass (2048-bit key) header.d=ndufresne-ca.20230601.gappssmtp.com header.i=@ndufresne-ca.20230601.gappssmtp.com header.b=f/TMKhGj; arc=none smtp.client-ip=209.85.222.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=ndufresne.ca Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=ndufresne.ca Received: by mail-qk1-f172.google.com with SMTP id af79cd13be357-789e209544eso75010085a.0 for ; Thu, 04 Apr 2024 11:56:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ndufresne-ca.20230601.gappssmtp.com; s=20230601; t=1712257006; x=1712861806; darn=vger.kernel.org; h=mime-version:user-agent:content-transfer-encoding:autocrypt :references:in-reply-to:date:cc:to:from:subject:message-id:from:to :cc:subject:date:message-id:reply-to; bh=rg3OgrxCT96ehDsWvlDmAIxCDxg1DhsRLeEA2xqhGms=; b=f/TMKhGjVivXjsCH5Au4O+9Z0oml7Qok5R21HnBfwir2o828Pm/Fbwhj/pIxwZUrcK 1NrJW1927XOz0MOt2jiXL4dlSjV/o3TdZ2+PwvcMwPdFhaqWhyaloMGGTryhDer7v7Q5 qOjcKB2Ew+H+XI+HhuliTXrNrsDzD9o4/BRkCVNVeWP8BF8go4j15i7gLVNxzQbedc8P 8N2MrM9innguUWcu5yOufr2wCPBDGok1ibFAaKAVcVAEbWpA9GdIs3u5aEnqbLk9va9A /E4N6XQzDUu8/YoPDT6SeeRVPTe1iKHc0Kas+IUx6djLT7Wb7MQ2NBqRkEfcy0Ujypay N7Mg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1712257006; x=1712861806; h=mime-version:user-agent:content-transfer-encoding:autocrypt :references:in-reply-to:date:cc:to:from:subject:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=rg3OgrxCT96ehDsWvlDmAIxCDxg1DhsRLeEA2xqhGms=; b=jE2qljD2l0bauKD9zmS3noEleARFnGJEKPw5zDA1VWBAhFa9bis/HY0m1EonP1/23I NgecJbrVBm59WLOvx9kCwQdTgNj/du/N8EyLVWi10C9A4qtRzSKiiGawN5bL4N96omXc Yl2i0XuoswutdYFt5T6QuF9jkDalq48lNOMLiFP3+hyOIaXClrMAqFuaJZOkMu44armh q7my0oyyA+QyaRk62nIjKn8jL3qI4D2UIdyA7W9RlI2viSdgdw3C6aP8HdFCv5fa2k3N gdTZt+d6KG9a0pRZIu4sjJ3eSqEORq7TN3tuVgvrzASM40lhEQCrmyUyVxuSz3OL9rc7 10wQ== X-Forwarded-Encrypted: i=1; AJvYcCUXfjnLEnw5NtYrMsSUGwKFnw+uIzGrQc7pc+H7aPv60EqmVTD5LhPPG4AgAZuV3uGXqjVIA+c4c1aazlv/cbExD3EBLQPZ6PXmxPbL X-Gm-Message-State: AOJu0YzMv7yLlo2TS+8GHurV73rdtg/z+W0SpBwwWmZAA+X96U30k4xU 2VS74J+2mSXXdTTsAbYgCHsyL6h2Qwb+LLOvSgjRoj4p5+HsrUyrjt3r46EBfhc= X-Received: by 2002:a05:620a:5a42:b0:78b:e6a3:8750 with SMTP id wx2-20020a05620a5a4200b0078be6a38750mr3708943qkn.38.1712257005875; Thu, 04 Apr 2024 11:56:45 -0700 (PDT) Received: from nicolas-tpx395.localdomain ([2606:6d00:17:6448:fa75:a4ff:fe45:b56]) by smtp.gmail.com with ESMTPSA id bp43-20020a05620a45ab00b00789e9bbf962sm6026679qkb.133.2024.04.04.11.56.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 04 Apr 2024 11:56:45 -0700 (PDT) Message-ID: <4f781313ddb2b7657fadc35dc04c0e3c3de3b27c.camel@ndufresne.ca> Subject: Re: [PATCH v2 4/5] media: chips-media: wave5: drop "sram-size" DT prop From: Nicolas Dufresne To: "sebastian.fricke@collabora.com" , Nas Chung Cc: "linux-media@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "jackson.lee" , Mauro Carvalho Chehab , Philipp Zabel Date: Thu, 04 Apr 2024 14:56:44 -0400 In-Reply-To: <20240404080235.kab6taeimsxpjtr3@basti-XPS-13-9310> References: <20240325064102.9278-1-brnkv.i1@gmail.com> <20240325064102.9278-5-brnkv.i1@gmail.com> <5hd7duzqhgdxpmvom3opkhwxkq55dmitk4gwdl4dy46q662in6@xxkmvdj6plqb> <7lro7ryzjajpzvkjdj5cndkmzmjkqvhts6dmer4pkkt7dluiii@wp7ael4ae7jd> <20240404080235.kab6taeimsxpjtr3@basti-XPS-13-9310> Autocrypt: addr=nicolas@ndufresne.ca; prefer-encrypt=mutual; keydata=mQGiBEUQN0MRBACQYceNSezSdMjx7sx6gwKkMghrrODgl3B0eXBTgNp6c431IfOOEsdvkoOh1kwoYcQgbg4MXw6beOltysX4e8fFWsiRkc2nvvRW9ir9kHDm49MkBLqaDjTqOkYKNMiurFW+gozpr/lUW15QqT6v68RYe0zRdtwGZqeLzX2LVuukGwCg4AISzswrrYHNV7vQLcbaUhPgIl0D+gILYT9TJgAEK4YHW+bFRcY+cgUFoLQqQayECMlctKoLOE69nIYOc/hDr9uih1wxrQ/yL0NJvQCohSPyoyLF9b2EuIGhQVp05XP7FzlTxhYvGO/DtO08ec85+bTfVBMV6eeY4MS3ZU+1z7ObD7Pf29YjyTehN2Dan6w1g2rBk5MoA/9nDocSlk4pbFpsYSFmVHsDiAOFje3+iY4ftVDKunKYWMhwRVBjAREOByBagmRau0cLEcElpf4hX5f978GoxSGIsiKoDAlXX+ICDOWC1/EXhEEmBR1gL0QJgiVviNyL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/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.50.4 (3.50.4-1.fc39) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Hi, Le jeudi 04 avril 2024 =C3=A0 10:02 +0200, sebastian.fricke@collabora.com a= =C3=A9crit=C2=A0: > > > > > > Wave5 can enable/disable the sec_axi_info option for each insta= nce. > > > > > >=20 > > > > > > How about handle sram-size through match_data ? > > > > > > I can find some drivers which use match_data to configure the s= ram > > > size. > >=20 > > I proposed using match_data to allocate different sram size for each de= vice. > > Do you think this is a reasonable approach ? >=20 > As discussed here: > https://patchwork.linuxtv.org/project/linux-media/patch/20240201184238.25= 42695-1-b-brnich@ti.com/ >=20 > To quote Brandon Brnich from TI: >=20 > If static SRAM allocation is the correct method to go, then this series > can be ignored and I will add section in device tree and remove check > for parameter in driver as that will now be a bug. >=20 > I would like to adhere to that. I feel your statement is a bit ambiguous. Can you clarify what you adhere t= oo ? That we should hardcode fixed sram size in the DT ? When I read earlier today "How about handle sram-size through match_data ?"= , what I saw was a static C structure in the driver. Like what we do with HW variants usually. I was pretty convince that the right solution is to allocate sram when the driver is used (open() seems appropriate), and drop it when its not used. W= ith the clear benefit that we can change our mind later if we find valid argume= nts. So with that in mind, dropping (cleaning up) that old code seems helpful to create a clean slate to re-introduce a better version. Nicolas