From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752793AbbFJHXA (ORCPT ); Wed, 10 Jun 2015 03:23:00 -0400 Received: from arroyo.ext.ti.com ([192.94.94.40]:46204 "EHLO arroyo.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753565AbbFJHWx (ORCPT ); Wed, 10 Jun 2015 03:22:53 -0400 Message-ID: <5577E5CA.80902@ti.com> Date: Wed, 10 Jun 2015 03:22:50 -0400 From: Murali Karicheri Organization: Texas Instruments User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 MIME-Version: 1.0 To: , , Subject: Re: [PATCH 3/4] spi: davinci: change the lower limit of pre-scale divider to 1 References: <1433920705-13068-1-git-send-email-m-karicheri2@ti.com> In-Reply-To: <1433920705-13068-1-git-send-email-m-karicheri2@ti.com> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 06/10/2015 03:18 AM, Murali Karicheri wrote: > SPI hardware spec for Keystone specifies a lower value of 0 for pre-scale > divider that is used for generating spi clock which translates to a > clock divider of 2. So fix the lower limit to allow using a higher SPI > clock. > > Signed-off-by: Murali Karicheri > Acked-by: Sekhar Nori > --- > drivers/spi/spi-davinci.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/spi/spi-davinci.c b/drivers/spi/spi-davinci.c > index 5e99106..987afeb 100644 > --- a/drivers/spi/spi-davinci.c > +++ b/drivers/spi/spi-davinci.c > @@ -265,7 +265,7 @@ static inline int davinci_spi_get_prescale(struct davinci_spi *dspi, > > ret = DIV_ROUND_UP(clk_get_rate(dspi->clk), max_speed_hz); > > - if (ret < 3 || ret > 256) > + if (ret < 1 || ret > 256) > return -EINVAL; > > return ret - 1; > Please ignore this as I messed up the PATCH prefix. I will re-send it with v1 and some updates to the commit log. -- Murali Karicheri Linux Kernel, Keystone