Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1450095imm; Thu, 19 Jul 2018 01:43:03 -0700 (PDT) X-Google-Smtp-Source: AAOMgpeuLogNbvjcXJokmx9M4ED+Zyfnc80UjisXrcQtL4rRYZ0ksFvq6uTJ1y3iif9HxhmZMOQp X-Received: by 2002:a63:7c5c:: with SMTP id l28-v6mr9249980pgn.352.1531989783132; Thu, 19 Jul 2018 01:43:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531989783; cv=none; d=google.com; s=arc-20160816; b=ZpptWhYmdlCvo30VnTIlxuW2PubGNrsQt0Xpll2zyF9VedbEVCijeuZFu9SZWfg40v 6S086RvZtEx6JaGVviZ4xzFqoz3de+3ME5EquwAFIFAGK/DD7gufGWw3b/7OXlAZee+l H+FEhp3wjRzOix5ShzzWyGWYJmyPh5uyb897/RrlwzYAk8Fxl0OvLo21//xp1k6U7dPm 4wcmdOog6GAzl1uXQgPa1Q/s2TpY3MtdDQrlfeJd2PFdR5oPniQdV+nDFPxud2EGKeo5 zhkdP5X3srFL0FgWcJ97bZ3sqDKzO8l8jZA0GbZw7QutQEjNN8AIh5iQK2o686XRI4T/ R4SA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=jk1D3BfPnd67BoTu2vOU0c+Zm/hTKogv3JjUocVXiqY=; b=YihAxTH2+sLR/wNPhqR04Vx8YTUhu7pvP3bAkqO0+8NQO7SFt9H3oKk+ayf8X3ZD5I wT0iiqRXiQrcWWRRAU7Sb0PKBl3jqthD0QLVwmXfm08Lafo0V36cdnO0hxLBx7cUfhgi zTBKYLbkhiC0KMuuymzRFtddvm8yJN+Y2vIMYukV8vfpsbd1c6bTdBjn+dsxOfaeOiYX E/xeG8/OCLfe90eWGS/1SmGeOw+uvMsfMkrtM+VweXR/4qe1Rm6/cee0nr97JY0zPBw0 +Yk/mqz69qZHJlVBbpm87vwUYMGDxaI3BqNLP4MZrHKf6wl1PLm72EgaqzaCjDvgcBbM WQ/w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 123-v6si5463520pfd.201.2018.07.19.01.42.48; Thu, 19 Jul 2018 01:43:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730811AbeGSJYQ (ORCPT + 99 others); Thu, 19 Jul 2018 05:24:16 -0400 Received: from sauhun.de ([88.99.104.3]:48058 "EHLO pokefinder.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726482AbeGSJYO (ORCPT ); Thu, 19 Jul 2018 05:24:14 -0400 Received: from localhost (p54B3338D.dip0.t-ipconnect.de [84.179.51.141]) by pokefinder.org (Postfix) with ESMTPSA id 959B15E000F; Thu, 19 Jul 2018 10:42:08 +0200 (CEST) Date: Thu, 19 Jul 2018 10:42:08 +0200 From: Wolfram Sang To: jacopo mondi Cc: Akinobu Mita , linux-media@vger.kernel.org, linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org, Mark Brown , Peter Rosin , Sebastian Reichel , Sylwester Nawrocki , Jacopo Mondi , Laurent Pinchart , Hans Verkuil , Sakari Ailus , Mauro Carvalho Chehab Subject: Re: [PATCH -next v4 2/3] media: ov772x: use SCCB regmap Message-ID: <20180719084208.4zdwt4vzcop4hve7@ninjato> References: <1531756070-8560-1-git-send-email-akinobu.mita@gmail.com> <1531756070-8560-3-git-send-email-akinobu.mita@gmail.com> <20180719074736.GA6784@w540> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="xqqiw3duga2s5vfo" Content-Disposition: inline In-Reply-To: <20180719074736.GA6784@w540> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --xqqiw3duga2s5vfo Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable > > -static int ov772x_mask_set(struct i2c_client *client, u8 command, u8 = mask, > > - u8 set) > > -{ > > - s32 val =3D ov772x_read(client, command); > > - > > - if (val < 0) > > - return val; > > - > > - val &=3D ~mask; > > - val |=3D set & mask; > > - > > - return ov772x_write(client, command, val); > > -} > > - >=20 > If I were you I would have kept these functions and wrapped the regmap > operations there. This is not an issue though if you prefer it this > way :) I have suggested this way. It is not a show stopper issue, but I still like this version better. --xqqiw3duga2s5vfo Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEOZGx6rniZ1Gk92RdFA3kzBSgKbYFAltQTtwACgkQFA3kzBSg KbZm3hAAls6hfbYwOifr2nw8YSVbwvRvWoJCrCVAPSWRjj97xNGAe21G1dXK3yU3 7jlwJbm96jA7YZWdPkxJUxha37b5fThlFVHZ7nNFlivied42SIySrGZGUKH02yNV a409+mGUGe5PAvGwO0/v7snWT5jmuRi84o5PUMUC/jLAOtHONEbOrgz81L3YBgpq bcjJFy5ZkoWZXbZk3AhEEWCC4rcBIw3pWhLm57/sI/Q+FiqO+a8io02qHhjF7/eS G62GBO09Ces+xtaIdmcaGzIP+4JvGy0nEjy6JmKWy0E6ryg1DI02X8lJVKFVpW9z 0IXS0PriwXzq6uWgh7qbP8R7oCPtXi2LEedJWc9IBWk3VOoQGkszbHwCakSb9tEA 3xSl+/W0pWVS6o1wWDQJpRPLzY2Hkfdp1CKth5oITsPCLyB36XnRAaVEqbeQ5FmX FdLbo7CXLyilZwazuyAYN/15+CbglKbNtAZUZMdgn7jvtN4LHUUFivIp7WAHRGUZ 0m/4JKcEDxFajrPwl9BDaDgUB9l7B1GwnkhcI+RYsJHMxFD/Hz5Sc+DNgUE2cb37 hfGuCp5W77b7EC6vyPaj5gzdY6Q+OXPSwBPjjhUVS4mpla7XL/kMW/neGZzN3Gnh 95NhY9twI4pEjGx/j1J6Fk23UNrk5MCpUmCXb4epIwDtkMKWZCY= =e06+ -----END PGP SIGNATURE----- --xqqiw3duga2s5vfo--