Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3147058pxk; Mon, 5 Oct 2020 02:14:09 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwGWiJFzEY3u7+ImGWyy74D21WTbDwgRZV1rDKcbd1+e6ljUSwnTQ9rhhaME7sLpVnNQCRU X-Received: by 2002:a17:906:5809:: with SMTP id m9mr14277552ejq.304.1601889249029; Mon, 05 Oct 2020 02:14:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601889249; cv=none; d=google.com; s=arc-20160816; b=0nVvP81OsoNXQJKgQf3aaW7uzFHdlKep52a2GKd5gNm1dvpJ5t7utixJuYIeE/DIm9 mzWeWiW4zxDCem+daZtaIH5TUXeRr0pXnJDXrNRp5tQ5KYBBjTFuMT/463qHgo6vT0f8 smM8hk1IOskA5kp8esdcM9U/iu5suIXCnqIvmxn+jUSEMzyezpMn9h6tDGSBmrI7um9A u0H87/Kd7glfYb5vyDMp40tT9eJIN/tr+OfUNQjlT5rG9XN/0DY0cnWVYmsUd1e8swyF KlLqP3Fq6phLJAW+xYzet+rel6kueL4PP9dp9E7xT9ez+gzEa3UT3DhYnlI/55OXEpzr KOxQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=6izeXoM0ljycw7P6ToTrkE6R0CPiIFhMYIDr3ZU/XTM=; b=gcbvJgFDCwyN8N+fRfCWz7N5DfLpRrrwP9f9VY9MBD9GRhZqAbllrcLMr70g3+FYHg 52w20vHbtWXz22lkk06JCaY/9OBiSgP+sAHiUfzWJHhrAfyBQTA6RyoePMfSgHCn8pLZ urgU01CtGAm5ub7nmURgE5AXFzFumfcEjD3hnHDwKBARO/NRK+B+iT/Zc6LDRwjGfN2a +IhjpyTJuCaSvgasE1LFO2rc8BNzfUMUKdZ54EwGTMNY1G3SCjKJyfn34lYaFuEGj/lm zcbCGGP3GATF2A6/3GbJNtE4oeYpwByexaw12xOw8wyWCooobPW/yiSKmiL7hQrd6IQN shsQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=r1eIBi6u; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o10si6972768edt.499.2020.10.05.02.13.46; Mon, 05 Oct 2020 02:14:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=r1eIBi6u; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725925AbgJEJMg (ORCPT + 99 others); Mon, 5 Oct 2020 05:12:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46756 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725887AbgJEJMg (ORCPT ); Mon, 5 Oct 2020 05:12:36 -0400 Received: from mail-wm1-x343.google.com (mail-wm1-x343.google.com [IPv6:2a00:1450:4864:20::343]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 109A0C0613CE for ; Mon, 5 Oct 2020 02:12:36 -0700 (PDT) Received: by mail-wm1-x343.google.com with SMTP id e2so7974718wme.1 for ; Mon, 05 Oct 2020 02:12:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=6izeXoM0ljycw7P6ToTrkE6R0CPiIFhMYIDr3ZU/XTM=; b=r1eIBi6u4R71qNHnmPX4aS2VLe5lgH3XD7b5Ynk9QA7M3YPjhHnIqPH4vEPNXpIsxo zIChZz3b4hna6vx27bsLcZmlQx9u3YsJv4VGLjbWzGUWs6Zqe8SrU5I+Qi5eNmaz++jr /YyXlXf4Ump2vV7N+7heoG7hvFiKX0HptCED5j/f3enDSecIcTP/hFBE3zP889FJxzFE TaSA7COljVn5lHAkymJeokTAoNjQ98/wtLd+3ev7A7AKCyJAwpgsMXCeweXfJUYQuQMA uBYPnTQU/A+uyblCRfhmgDXVotNB++7l9mKHrV0nqwck8y5Ua0BUYPmLYL/rvCr9IuWb PSYQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=6izeXoM0ljycw7P6ToTrkE6R0CPiIFhMYIDr3ZU/XTM=; b=aZKnIGN+Oy+NYYrFkLfF1bmLe03EA+j7zD5J0N2h6Tfz77Nv+ivN4o1e+EdU8Kr5/U EgbIrGanbgwpoTheYxxQL05XZOUSL/cufHkPjCqGqD5rNo/8rKKMEHLKEP0d+zyPub+1 x3z4dHNEAaeshIKg3TsPcSYG9lOVEDYQTgsog3LNQD03TnVjsVOA6xNnwCmDiS2ZqgUd 8oZgO/41DklY7HpKLmrzRHMptrR/jLHJyxCpsrTS65qVK8U97L4OL1buh1c9ws10P+XU M0wWUTxJaI+81+9KRmZsFX7GUrB/t0uL/9cg8yEYVNgB+MxMJeOefbozHAdKenNwMe6Q K/+w== X-Gm-Message-State: AOAM531kkgk56AfXknR4aUNT0G9mM2UAlH657MATcXkXMYu1GQ0ZsCSL wBwXy0L9KgX5kh7PunqL26fyjdGFHdu6Og== X-Received: by 2002:a1c:e48b:: with SMTP id b133mr15590497wmh.0.1601889154497; Mon, 05 Oct 2020 02:12:34 -0700 (PDT) Received: from [192.168.86.34] (cpc86377-aztw32-2-0-cust226.18-1.cable.virginm.net. [92.233.226.227]) by smtp.googlemail.com with ESMTPSA id x2sm12153651wrl.13.2020.10.05.02.12.33 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 05 Oct 2020 02:12:33 -0700 (PDT) Subject: Re: [PATCH 3/3] nvmem: qfprom: Don't touch certain fuses To: Evan Green Cc: Rob Herring , Bjorn Andersson , Douglas Anderson , Stephen Boyd , LKML References: <20200929205807.2360405-1-evgreen@chromium.org> <20200929135741.3.I1bb1b0e94be3b792804e08831d6a55481e162d63@changeid> <8f467220-3ac8-c8fc-33fe-8d86904571fe@linaro.org> From: Srinivas Kandagatla Message-ID: <14b62a74-4b4f-42b9-6043-ab8445a3f627@linaro.org> Date: Mon, 5 Oct 2020 10:12:32 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/10/2020 22:49, Evan Green wrote: > Oh no, I realized this isn't nearly as beautiful when I try to move it > into the core. The low level read/write interface between the nvmem > core and the driver is a range. So to move this into the core I'd have > to implement all the overlap computation logic to potentially break up > a read into several small reads in cases where there are many little > keepout ranges. It was much simpler when I could just check each byte > offset individually, and because I was doing it in this one > rarely-used driver I could make that performance tradeoff without much > penalty. > > I could do all range/overlap handling if you want, but it'll be a > bigger change, and I worry my driver would be the only one to end up > using it. What do you think? I still think this should go in to core. core should be able to avoid checking by the presence of any restricted range, so it should not be a overhead for other non-users. regmap has similar feature we can take some inspiration from that code!! --srini > -Evan