From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from relay8-d.mail.gandi.net (relay8-d.mail.gandi.net [217.70.183.201]) (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 84FB322D4F0; Wed, 21 May 2025 15:56:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747843019; cv=none; b=U7kB5kBVoETCa4TfskxuQq579HcnABg0wZcsA+b6Za1InqT9lg8O3E3Nyh0PcL1JsQ4PDegSU2Arzw1EWW0bVrkULxPj0qnU24CssGw37zO/hfFHVQv/YioEBwxhgLlJtIFmkkxZZcR3aXybxfhsRHxVh1GimF4i07SNENknL2w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747843019; c=relaxed/simple; bh=44jrVkR8r5/We3U3Esl7+w0C93M7tsfXlNxUrYFK5fQ=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=u7ofpx9z8zA4sw9fKZheuySMKgJl1kTVhSgCw9iYFyCaRSb6W2jfntW28QDxD2nLvEf38NqEEeKqPd1x5AMSkZgWDRYc7GKqecgppgm98XeOqUMOFIPUS+nDJT9cdHDISLOmTh2JVBtjm0F0aardA6X62OyirrvDGqs5oZDK1yk= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=n+hcwn7R; arc=none smtp.client-ip=217.70.183.201 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="n+hcwn7R" Received: by mail.gandi.net (Postfix) with ESMTPSA id F1831433F0; Wed, 21 May 2025 15:56:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1747843009; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=NWMkDdl6E2fycIBGTT9cUcWO0Zk2SA4xCgPlwZJN26I=; b=n+hcwn7RTfB6RUWG4Qaa+kthM06ioRUzKoagzup19r9II0PqT1zDbMVMiAd6SjNYdrjQn4 OeEWR0QLX+HVcfInIp2RYDidv66zJsKipJVuDUSvZvea9ZGxrDnaszJSWgrlejiXcchQA3 5h+VaM5xsV3dfBpb67Q7bxT5Cbhfo5ZCCdUHUMPOp7wJWDW6fCJJXzz+XOh/wI4UI3gutB 8urU/4ZCx8+neBs4umx4HGKp0XF+74VDWeBoUOOwBQIURFJ7ogRgNG+yxqr3sQB6T8cx4z EGHpSVHi2MtdxV9WQHHcnr4hTgsOMuKKZXXq2pdHycCmp06r3wvBZEHa8VwtfA== Date: Wed, 21 May 2025 17:56:46 +0200 From: Luca Ceresoli To: Cosmin Tanislav Cc: Wolfram Sang , Tomi Valkeinen , Mauro Carvalho Chehab , Romain Gantois , Arnd Bergmann , Greg Kroah-Hartman , linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org, linux-media@vger.kernel.org Subject: Re: [PATCH v5 3/9] i2c: atr: split up i2c_atr_get_mapping_by_addr() Message-ID: <20250521175646.2aa73fb9@booty> In-Reply-To: <20250507121917.2364416-4-demonsingur@gmail.com> References: <20250507121917.2364416-1-demonsingur@gmail.com> <20250507121917.2364416-4-demonsingur@gmail.com> Organization: Bootlin X-Mailer: Claws Mail 4.3.1 (GTK 3.24.49; x86_64-redhat-linux-gnu) Precedence: bulk X-Mailing-List: linux-i2c@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-GND-State: clean X-GND-Score: -100 X-GND-Cause: gggruggvucftvghtrhhoucdtuddrgeeffedrtddtgdefhedtucdltddurdegfedvrddttddmucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuifetpfffkfdpucggtfgfnhhsuhgsshgtrhhisggvnecuuegrihhlohhuthemuceftddunecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpeffhffvvefukfgjfhhoofggtgfgsehtjeertdertddvnecuhfhrohhmpefnuhgtrgcuvegvrhgvshholhhiuceolhhutggrrdgtvghrvghsohhlihessghoohhtlhhinhdrtghomheqnecuggftrfgrthhtvghrnhepgeelffefgfehhfdtvdefueefieevkefggfelkeeiudetkeektedvhedukefgvddvnecuffhomhgrihhnpegsohhothhlihhnrdgtohhmnecukfhppedvrgdtvdemieejtdemvddtvddtmegvrgdtudemsggvgedumeelhegvjeemfeegfeemledufegvnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehinhgvthepvdgrtddvmeeijedtmedvtddvtdemvggrtddumegsvgegudemleehvgejmeefgeefmeeludefvgdphhgvlhhopegsohhothihpdhmrghilhhfrhhomheplhhutggrrdgtvghrvghsohhlihessghoohhtlhhinhdrtghomhdpnhgspghrtghpthhtohepuddtpdhrtghpthhtohepuggvmhhonhhsihhnghhurhesghhmrghilhdrtghomhdprhgtphhtthhopeifshgrodhrvghnvghsrghssehsrghnghdqvghnghhinhgvvghrihhnghdrtghomhdprhgtphhtt hhopehtohhmihdrvhgrlhhkvghinhgvnhesihguvggrshhonhgsohgrrhgurdgtohhmpdhrtghpthhtohepmhgthhgvhhgrsgeskhgvrhhnvghlrdhorhhgpdhrtghpthhtoheprhhomhgrihhnrdhgrghnthhoihhssegsohhothhlihhnrdgtohhmpdhrtghpthhtoheprghrnhgusegrrhhnuggsrdguvgdprhgtphhtthhopehgrhgvghhkhheslhhinhhugihfohhunhgurghtihhonhdrohhrghdprhgtphhtthhopehlihhnuhigqdhivdgtsehvghgvrhdrkhgvrhhnvghlrdhorhhg X-GND-Sasl: luca.ceresoli@bootlin.com On Wed, 7 May 2025 15:19:09 +0300 Cosmin Tanislav wrote: > The i2c_atr_get_mapping_by_addr() function handles three separate > usecases: finding an existing mapping, creating a new mapping, or > replacing an existing mapping if a new mapping cannot be created > because there aren't enough aliases available. > > Split up the function into three different functions handling its > individual usecases to prepare for better usage of each one. > > Signed-off-by: Cosmin Tanislav Reviewed-by: Luca Ceresoli -- Luca Ceresoli, Bootlin Embedded Linux and Kernel engineering https://bootlin.com