Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp836232pxb; Thu, 28 Jan 2021 01:06:56 -0800 (PST) X-Google-Smtp-Source: ABdhPJzJmBgXUoQiBr2h+7fJXN+Tjiz7Euh4KazAc29bOJB7ZidehoR60UJ6MOkm+wiCvDt+H6Qo X-Received: by 2002:a17:906:1a0c:: with SMTP id i12mr10460930ejf.325.1611824816317; Thu, 28 Jan 2021 01:06:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611824816; cv=none; d=google.com; s=arc-20160816; b=IjsYb5CXps0BuZKdEWFEcDvkGCHhlQNbeEZCrTa+ujpjkTvZ2RdCNa7nZx9hp1fwT4 q5wHLAypxO+Hm/TiRl7SAy3cHWrZulc//Ib6E9b7DWYU+SLkbRNdqhc4l5QV6UhjAqm/ 6YEUXlBszEX7xTsrssW58O2VG7WDH8qNawqCGP39sII+PWEGdvMEIrJffpjUJSe+VAUc btl9mHFitjDKVMkyLliHDmQCfGG+bQ3vWqxWWWZ/dixAVr/O9Uki5Wlk9Gl+NW15a1l9 VMcToMJHzK2vHWP13GRQbVrWvxDzc4zVRVxUKP23sErkgbr4xII6unhFP2iEC+waZKBJ lfWw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=ZSpbOwM3PgqgMsQHXF6oksjxPNWs7WTnaxH8AahkgyY=; b=s9fSbU9rnVT5FWX019Xgeg29A+Y0+8vmNEj/QrszWV2BRy5ma3LAIfTx1lkodpo/iQ y9EOF8yoK0fh2FABUTGujbMOvGfEJIZdJVf9e7p0+szyzO3AfcDv6uSJnrBM2Ivvma7u 5323lKqxjmxo3HfHoN1/pCav7wJWoiWBreUQWtlgHDDGPsAng4ZXxNVjRybC5csKtnhR VKUdFD3W02i9Us0jzeLcvfksvbL2JpYc+uBK+07Tw4gerf60qgSVGrvd2aLdbPSWkmyi QDTa76uelAcBpGY2PQCTW3ttEmHF0mR6qllDxlbp2UThnHISnZaEoAPvXmX/3fa/WQ+k fx0w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=D51Vy1Kv; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b40si2608037edf.251.2021.01.28.01.06.31; Thu, 28 Jan 2021 01:06:56 -0800 (PST) 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=@baylibre-com.20150623.gappssmtp.com header.s=20150623 header.b=D51Vy1Kv; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231818AbhA1JFp (ORCPT + 99 others); Thu, 28 Jan 2021 04:05:45 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58202 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231371AbhA1JFf (ORCPT ); Thu, 28 Jan 2021 04:05:35 -0500 Received: from mail-ej1-x62f.google.com (mail-ej1-x62f.google.com [IPv6:2a00:1450:4864:20::62f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7B979C061574 for ; Thu, 28 Jan 2021 01:04:54 -0800 (PST) Received: by mail-ej1-x62f.google.com with SMTP id w1so6575133ejf.11 for ; Thu, 28 Jan 2021 01:04:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ZSpbOwM3PgqgMsQHXF6oksjxPNWs7WTnaxH8AahkgyY=; b=D51Vy1KvVoIMcajJ2UgisCcNbDzngPmQBW1XkS+CxR/ySYWIPbYW1RzPePmClZ0rm8 4jtlg1iGU8IZscGGV2HOPzSfIb0bLTaMsaa2i8ROQOm1HXuSyx6x/nLUUM8sIPMXDRzg dOtzFvslT+YOtQ1SgH89MXANMzeA2vblDh/l2ivSWB8Y2MxAulprUb0khur0kY6U1vW0 ckUNh2kicVJPoDFgaOG0hp+Pg0jAVZr8oU8eDuuBe/4p1PfCk/iot7mKwOp13rzV39Tp tcpVcprtjvNpUdIji8XuEM1++l8sg2YxiWYp8djScYLFatv0SEECHJiFtCY4buOxWILa ltYg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=ZSpbOwM3PgqgMsQHXF6oksjxPNWs7WTnaxH8AahkgyY=; b=serXKKenzseDgRiTzuc+74PbGcJobV8LBAz1gpbDRVXn9TXweciirDoBx265KOOOht YRMZKqETQICSMS102lbv88Mp9QMgTB9om57mMGKi86uLhEqpOlohV/+/EP+l7fdpZC/3 p7GNfMuUbVFQdTjKNP6BYlCy9YVSyF4NomAWs8QS5yphs9nHsD9me1Bx3+Gjz7r148Fh koNoJJjg8UnPjUDMruAuN6MINPofBcHdBVZy24Zxzlm86oB4y38yfFkqRmV2rVaWBk5D IrHwEOQ9DjBuRcIJ7+RRpr39cTIfY2bhj0EdTQYETifXlnnpE5JA1mBOcMbQUcxhAujJ TC2w== X-Gm-Message-State: AOAM530SNFIfEPHII/bOrxTMwziD9Cq2zysxrwLvvxFXYKueM4O77NJA m+G4LvXYKftlG1S/zd2+NXMY+BnWDSC1kGlaGb+M8A== X-Received: by 2002:a17:906:3146:: with SMTP id e6mr9701086eje.363.1611824693112; Thu, 28 Jan 2021 01:04:53 -0800 (PST) MIME-Version: 1.0 References: <20210128081030.2345998-1-hsiufangho@google.com> In-Reply-To: <20210128081030.2345998-1-hsiufangho@google.com> From: Bartosz Golaszewski Date: Thu, 28 Jan 2021 10:04:42 +0100 Message-ID: Subject: Re: [PATCH] eeprom: at24: Add permission to write_timeout To: Jenny Ho Cc: Greg Kroah-Hartman , Arnd Bergmann , linux-i2c , LKML Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jan 28, 2021 at 9:10 AM Jenny Ho wrote: > > Need to change timeout time for different use > cases to prevent I2C error cases. Open the api > and allow Read/Write permission to write_timeout > > Signed-off-by: Jenny Ho > --- > drivers/misc/eeprom/at24.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/misc/eeprom/at24.c b/drivers/misc/eeprom/at24.c > index 926408b41270..39caead4058c 100644 > --- a/drivers/misc/eeprom/at24.c > +++ b/drivers/misc/eeprom/at24.c > @@ -117,7 +117,7 @@ MODULE_PARM_DESC(at24_io_limit, "Maximum bytes per I/O (default 128)"); > * it's important to recover from write timeouts. > */ > static unsigned int at24_write_timeout = 25; > -module_param_named(write_timeout, at24_write_timeout, uint, 0); > +module_param_named(write_timeout, at24_write_timeout, uint, 0600); > MODULE_PARM_DESC(at24_write_timeout, "Time (in ms) to try writes (default 25)"); > > struct at24_chip_data { > -- > 2.30.0.280.ga3ce27912f-goog > IMO this should be a per-chip device property and not a global module param. Any chance you could maybe try and extend the driver with a new property for that? Bart