From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id EC289C76190 for ; Mon, 22 Jul 2019 21:32:34 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C160021900 for ; Mon, 22 Jul 2019 21:32:34 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="q251YQgl"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="Qry+PWBd" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C160021900 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Message-Id:Date:From:To:Subject: References:In-Reply-To:MIME-Version:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=AqHchz+omqe4xSWZPH6QI82DvUMiPbFCYH0M9UQyjF4=; b=q251YQglnfrYW5 S5aOAHrjnLkk7VNtWcaWS1QoR96U6uoLWMfGAUClZUcE/aQNPKko9tsB5fwxtIQxeSsuax/FEr+gB rP/QyZx4XB4I9ZY8EJricbt00Typvcj+qowoAfYrwTblgKpvXvZGgE7aMqpnfaeveqsYY+omeJ1mj iTP6Rlu+kTX+puhMdhXCYwIdDmPYAxifY46JoDPUAbE2dP3Bd4tJ3JFmrgRN2zzIi1d/mCwTjKk5A C6hSgJxtCL99PEnWimZRzKGFvIaHFb/rAZM3UlDsqQXYEhpLspxU0Waji4cAbDTxwi3ggJm9VyI4r n1xqYxVup2V2dIoXvdYA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hpfuz-0005JX-S8; Mon, 22 Jul 2019 21:32:26 +0000 Received: from mail.kernel.org ([198.145.29.99]) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1hpfuq-0005En-1r for linux-arm-kernel@lists.infradead.org; Mon, 22 Jul 2019 21:32:17 +0000 Received: from kernel.org (unknown [104.132.0.74]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9B79B21900; Mon, 22 Jul 2019 21:32:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1563831135; bh=4ePKRVOjuk0pdWmx57Jr5AQcVG8sUyMlkiLelXx84UU=; h=In-Reply-To:References:Subject:To:Cc:From:Date:From; b=Qry+PWBd926llkTs47Y1tV3OpEOjUw9u7ySLBx4LyW+s/RNEWYd+7XCZcWVbnzgvd pRua+Q7cWTp1cp6QJala2Xc5wxa4kurCzy4CCoSK5R4f4nMkd/i0MfbyLiJTYulo0x kikV7uMfILBA+IHveio5Z7NYYXW7seS4wCy+tHGw= MIME-Version: 1.0 In-Reply-To: <20190625091002.27567-1-codrin.ciubotariu@microchip.com> References: <20190625091002.27567-1-codrin.ciubotariu@microchip.com> Subject: Re: [RESEND][PATCH] clk: at91: generated: Truncate divisor to GENERATED_MAX_DIV + 1 To: Codrin Ciubotariu , alexandre.belloni@bootlin.com, ludovic.desroches@microchip.com, nicolas.ferre@microchip.com From: Stephen Boyd User-Agent: alot/0.8.1 Date: Mon, 22 Jul 2019 14:32:14 -0700 Message-Id: <20190722213215.9B79B21900@mail.kernel.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190722_143216_362398_80084385 X-CRM114-Status: UNSURE ( 7.38 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Codrin Ciubotariu , linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org Quoting Codrin Ciubotariu (2019-06-25 02:10:02) > In clk_generated_determine_rate(), if the divisor is greater than > GENERATED_MAX_DIV + 1, then the wrong best_rate will be returned. > If clk_generated_set_rate() will be called later with this wrong > rate, it will return -EINVAL, so the generated clock won't change > its value. Do no let the divisor be greater than GENERATED_MAX_DIV + 1. > > Fixes: 8c7aa6328947 ("clk: at91: clk-generated: remove useless divisor loop") > Signed-off-by: Codrin Ciubotariu > Acked-by: Nicolas Ferre > Acked-by: Ludovic Desroches > --- Applied to clk-fixes _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel