From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-yx1-f48.google.com (mail-yx1-f48.google.com [74.125.224.48]) (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 6C0421519B4 for ; Wed, 13 May 2026 14:45:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=74.125.224.48 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778683517; cv=none; b=BfagqX5Ii0ZFmnBoGB50ZAPoI1mLOps1F1n5dLZ6T92VU2oWNthdxL0VilAplyXvTn6dDxghDyDN7zJwkcKRGGdsbe6Y/K9xRpoyK7FDww5kPghO7dRiWQiMDHheWtxUoApZ2DTA9XlXyTXOHODgfT1Q20K+alC5A2+kacSlo4c= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778683517; c=relaxed/simple; bh=0iQin8+HkiJwZ7N38xKjr5xDmWGbGl/90nkCt9tvW98=; h=Mime-Version:Content-Type:Date:Message-Id:Cc:Subject:From:To: References:In-Reply-To; b=gKmwe/QK2SkUERbQYmePrAREpuSW9cXW/yxwl+f7ATTzO3D22KmqZx7DmkFLwjBAOYYz+nVWfuhE1YvKdR6rPGhwP9ycXHVZbGA/KRnfOojLCV86cGA5Sc6XGhWOwHvVVK2UYUJJZLA7F2esygpi1Htvv2c02A1Wy3sbihzSNYs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=O9gQT85/; arc=none smtp.client-ip=74.125.224.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="O9gQT85/" Received: by mail-yx1-f48.google.com with SMTP id 956f58d0204a3-65c21049dafso6353913d50.2 for ; Wed, 13 May 2026 07:45:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1778683515; x=1779288315; darn=vger.kernel.org; h=in-reply-to:references:to:from:subject:cc:message-id:date :content-transfer-encoding:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=0iQin8+HkiJwZ7N38xKjr5xDmWGbGl/90nkCt9tvW98=; b=O9gQT85/fBjno1WrqhSGh26aI1CS8dAC2XRhjHkJic4Ksjkj3yFYcelxueDMkLvt4q EG4L6ye8pzkMANzNju7hLb21uGVcL30tgSC+m6QYyghSfP8pgXuOGex9ZPuo7PFmuSWG lMKVhTxdoDCK699gwSQ1wHKyAiKHUB03S6l1fpxNRLRO/j+Tu4yeD1L6O8hEs+fYAtqU gG+mi++83F4xjxbMvNFC56bL7DkIq21sRHkmKe48TKLzZmL36i9zH0YCRiLAgU0IDjC0 Nsj1GIUAiYDNNnXv2UYs3x/S/o/GSELGRy7bQNvH+sjW0UDT72it4reFRZvBU1o6ltrz P72Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778683515; x=1779288315; h=in-reply-to:references:to:from:subject:cc:message-id:date :content-transfer-encoding:mime-version:x-gm-gg:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=0iQin8+HkiJwZ7N38xKjr5xDmWGbGl/90nkCt9tvW98=; b=RV3wkaT/VZx5zZlm8YFUNias8oep42IXjA7w8ipsS0aN7uXQj1ET0xYc0cK9uwtypa Vpb19WLaN8jAv8qz8gSJmBwnTeUCD9TZEz502ew+Mcv8XLAxE5ur/VAebntkiY44DRWl sju3h/C+5qdMUFC1I3Zpv/W6kEm6EctsbxmNWDTKOSzpXxDvbOlygDVESLZAYE7Ms6l/ nYyGBqg+i4+tdiF5XG4/qVCU0ihQZmAPk8UQ3whC8wqVapUy3OwT8d8LP1UjzSrRfjfH 3/8SKtopGggo7456iJWFKq0BLn3PkTYau2otUxT4ItRnUEKp5jhiTHjuNFQXyhPC9CSD Athw== X-Forwarded-Encrypted: i=1; AFNElJ9i2NdZrijYQY+BEXjghatqndn2vqWjc+nc+mGlRrKhJ3Ao9MnBueKiNB354ChKjJP6bXSwP230xxs093w=@vger.kernel.org X-Gm-Message-State: AOJu0YySGXPCihYQdjjC7YEvNM7k9CJDKTVz2THIvmKoQByuTgzoboIx sUJ1rMA+ZoovIJDlgJwF0M98qJoBny/sisyGrY79hO4GxCCjjNPN5YYd X-Gm-Gg: Acq92OGMYx9mEVN99CLtX71UE4wALqr36QR9Vds8HE2+il4quZZckx66I14QaM7wBdZ ZoLvm0zZlxX9v5N5vwpeWCXiBYzyVyy0kOPq3XNUN+FDQJxJaFRxQ2A2XiKhNMgPDK+2iPL0eUs 2zK56dSUmu7lYeN2HSOpqjtSI32DZ5AP6AH1lKDg+qnmJuFaKLPuVEyrlHR3A4/VALx3aG8XuGk SCIfrCswg4vmTABWh/NR3Le0GI+ZrS7pDmfzrynerwKWzm0m5azvR1RKNQrv55xSk6ilTIkJJtr fi1kxmbyEFGsAFwcoNY5Ar9u8jldgVr2kDVSG3arXc2j7lWexVEhY4RHbIGMs7gqcwtGHLLPt2o aUNk20Inhntk4h5lRxkJHiOjGeZ9nalWLH3HQPpcNeD0NnJir8gCv9Nm5WfjK+IrIKD79Ss8iak grNkKblh4Lq+HBcwao9zyUkwE9HQc2tqSYSdAE4w== X-Received: by 2002:a05:690e:134e:b0:65c:6f79:1dd0 with SMTP id 956f58d0204a3-65df6245796mr3703212d50.20.1778683515277; Wed, 13 May 2026 07:45:15 -0700 (PDT) Received: from localhost ([208.185.137.148]) by smtp.gmail.com with ESMTPSA id 956f58d0204a3-65d969fb402sm9004063d50.3.2026.05.13.07.45.13 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 13 May 2026 07:45:14 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 Date: Wed, 13 May 2026 09:45:12 -0500 Message-Id: Cc: , "David Lechner" , =?utf-8?q?Nuno_S=C3=A1?= , "Andy Shevchenko" , "open list:IIO SUBSYSTEM AND DRIVERS" , "open list" Subject: Re: [PATCH v6] iio: imu: kmx61: Use guard(mutex)() over manual locking From: "Maxwell Doose" To: "Andy Shevchenko" , "Maxwell Doose" X-Mailer: aerc 0.21.0 References: <20260513020654.168071-1-m32285159@gmail.com> In-Reply-To: On Wed May 13, 2026 at 8:10 AM CDT, Andy Shevchenko wrote: > On Tue, May 12, 2026 at 09:06:54PM -0500, Maxwell Doose wrote: >> Include linux/cleanup.h to take advantage of new macros. >>=20 >> Replace manual mutex_lock() and mutex_unlock() calls across the file >> with guard(mutex)() and scoped_guard() where appropriate to simplify >> error paths and eliminate manual locking calls. >>=20 >> Add new helper function kmx61_read_for_each_active_channel() to mitigate >> certain style issues and to prevent notifying that the IRQ is finished >> whilst holding the lock. >>=20 >> Update certain returns, and add default case to return -EINVAL in >> kmx61_read_raw(). >>=20 >> Remove now-redundant gotos and ret variables, as the new RAII macros >> make them unneeded. > > Have you used --histogram algo when prepared patch? Please, do it, if > not yet. It might improve the diff itself and hence makes reviewers a bit > more happier. I *think* I used --histogram, I'm not sure what happened :/ best regards, max