Received: by 2002:a25:31c3:0:0:0:0:0 with SMTP id x186csp1000696ybx; Thu, 31 Oct 2019 04:19:24 -0700 (PDT) X-Google-Smtp-Source: APXvYqzv2t5TDEHdoTL7JafI7hfGqCL+mjWbFcth86ZlZd6urTkNdQzREJm4xp/o+He0tVCrcyD5 X-Received: by 2002:a50:890c:: with SMTP id e12mr5393119ede.277.1572520764496; Thu, 31 Oct 2019 04:19:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1572520764; cv=none; d=google.com; s=arc-20160816; b=U3VgBIyW0mfei+/Xu8VgmTPc35UseaRE2PKAvzP5mP73mlhfxplyAvg8DacQ1/85kV LuBL6CYcDWh9EokxACTGnkCNrrlcWG/dNflZ6Y6jdHrgMuVYPM4Dx00yq2H7lgCDcWgn qQejwkcH2CF4OdCVFCsE6WfLKNFEHIoJ2Aj9wf6ysQcHSHRtxorxN6gZ6BDZF9du4hmA i1Plf8CVgcqFecZVe3BKHgCzUlOiJvz6wag7839WQpvQaRCA8AKEaw2HcZfclPmEMBwE 91BO2lAHWhuHNy5FEnrgYzO3dmMWYom5/gStJO5qPqUmf+oVEngadT2Y07+7iizugggE YGxQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date; bh=+GlO7j4CpuO3kSq4l4WjbxBmp3/eLe5Bk7Lg3ON9xfc=; b=bz1jcIPFraKInvlwhy7+hVUyXK16mFgq7ukb5T8aXkq+NWOxg0bnOyS5QrgGEYJRdA mWEtQjWJxjXBnWNliRRBlAmAo0vwNkdL6yb8QPqX5AFKONnLbS4WAuYAnlQuGMBunjFa exIB4npeYpbxihTouCrfwstLd7DT0DPefyXPIdrgyGPRo9A4jDknB4lz3f6UYEWmFH1N 71L8lbwHj3LOqBsgxFGHaazR2xZHRhC4e8qx9m3Y9vAv0wGHPrLDxIbYhSQnYIWNb5Gf i0Ow+XyCR6K4FdTC7tIdXB63bFjYcp8aJh/VbozVJxaWRx+3L5X8C53Nt+y4My4H/mlq kwlw== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w25si3577047edl.418.2019.10.31.04.19.00; Thu, 31 Oct 2019 04:19:24 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727410AbfJaLRx (ORCPT + 99 others); Thu, 31 Oct 2019 07:17:53 -0400 Received: from bhuna.collabora.co.uk ([46.235.227.227]:46994 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727074AbfJaLRw (ORCPT ); Thu, 31 Oct 2019 07:17:52 -0400 Received: from localhost (unknown [IPv6:2a01:e0a:2c:6930:5cf4:84a1:2763:fe0d]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: bbrezillon) by bhuna.collabora.co.uk (Postfix) with ESMTPSA id 5D014290622; Thu, 31 Oct 2019 11:17:51 +0000 (GMT) Date: Thu, 31 Oct 2019 12:17:48 +0100 From: Boris Brezillon To: Cc: , , , , Subject: Re: [PATCH v3 19/32] mtd: spi-nor: Merge spi_nor_write_sr() and spi_nor_write_sr_cr() Message-ID: <20191031121748.5497aea6@collabora.com> In-Reply-To: <20191029111615.3706-20-tudor.ambarus@microchip.com> References: <20191029111615.3706-1-tudor.ambarus@microchip.com> <20191029111615.3706-20-tudor.ambarus@microchip.com> Organization: Collabora X-Mailer: Claws Mail 3.17.4 (GTK+ 2.24.32; x86_64-redhat-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 29 Oct 2019 11:17:18 +0000 wrote: > From: Tudor Ambarus > > Merge > static int spi_nor_write_sr(struct spi_nor *nor, u8 val) > static int spi_nor_write_sr_cr(struct spi_nor *nor, const u8 *sr_cr) > into > static int spi_nor_write_sr(struct spi_nor *nor, const u8 *sr, size_t len) > > The Status Register can be written with one or two bytes. Merge > the two functions to avoid code duplication. > > Signed-off-by: Tudor Ambarus Reviewed-by: Boris Brezillon