Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S966647AbbBDWEW (ORCPT ); Wed, 4 Feb 2015 17:04:22 -0500 Received: from mail-lb0-f177.google.com ([209.85.217.177]:38290 "EHLO mail-lb0-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933839AbbBDWEV (ORCPT ); Wed, 4 Feb 2015 17:04:21 -0500 Message-ID: <54D29760.4010009@cogentembedded.com> Date: Thu, 05 Feb 2015 01:04:16 +0300 From: Sergei Shtylyov Organization: Cogent Embedded User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: Mike Turquette , Wolfram Sang , Geert Uytterhoeven CC: Stephen Boyd , Laurent Pinchart , Ulrich Hecht , Wolfram Sang , linux-sh@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] clk: shmobile: div6: Avoid division by zero in .round_rate() References: <1423052841-15194-1-git-send-email-geert+renesas@glider.be> <20150204173233.GA30930@katana> <54D25AAA.8070904@cogentembedded.com> <20150204220152.421.38508@quantum> In-Reply-To: <20150204220152.421.38508@quantum> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 943 Lines: 32 Hello. On 02/05/2015 01:01 AM, Mike Turquette wrote: >>>> Anyone may call clk_round_rate() with a zero rate value, so we have to >>>> protect against that. >>>> Signed-off-by: Geert Uytterhoeven >>> Acked-by: Wolfram Sang >>> I agree that this should not be fixed in the core because the fixup is >>> really driver dependant. >> Dunno, zero frequency seems generally insane to me. > It is useful to find the lowest frequency a clock can support. Basically > it is a search for the floor frequency. Why not just use 1? Or are you assuming that some hardware could actually support 0 Hz? > Regards, > Mike WBR, Sergei -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/