From patchwork Wed Feb 24 09:30:28 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jiri Slaby X-Patchwork-Id: 62784 Delivered-To: patch@linaro.org Received: by 10.112.43.199 with SMTP id y7csp2294800lbl; Wed, 24 Feb 2016 01:31:24 -0800 (PST) X-Received: by 10.66.102.8 with SMTP id fk8mr53461722pab.12.1456306259102; Wed, 24 Feb 2016 01:30:59 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f77si3776922pfd.94.2016.02.24.01.30.58; Wed, 24 Feb 2016 01:30:59 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of stable-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 stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752247AbcBXJa5 (ORCPT + 3 others); Wed, 24 Feb 2016 04:30:57 -0500 Received: from mx2.suse.de ([195.135.220.15]:39218 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751393AbcBXJay (ORCPT ); Wed, 24 Feb 2016 04:30:54 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id CAFABAD98; Wed, 24 Feb 2016 09:30:53 +0000 (UTC) From: Jiri Slaby To: stable@vger.kernel.org Cc: Linus Walleij , Russell King , Jiri Slaby Subject: [patch added to 3.12-stable] ARM: 8519/1: ICST: try other dividends than 1 Date: Wed, 24 Feb 2016 10:30:28 +0100 Message-Id: <1456306248-31813-9-git-send-email-jslaby@suse.cz> X-Mailer: git-send-email 2.7.1 In-Reply-To: <1456306248-31813-1-git-send-email-jslaby@suse.cz> References: <1456306248-31813-1-git-send-email-jslaby@suse.cz> Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Linus Walleij This patch has been added to the 3.12 stable tree. If you have any objections, please let us know. -- 2.7.1 -- To unsubscribe from this list: send the line "unsubscribe stable" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html =============== commit e972c37459c813190461dabfeaac228e00aae259 upstream. Since the dawn of time the ICST code has only supported divide by one or hang in an eternal loop. Luckily we were always dividing by one because the reference frequency for the systems using the ICSTs is 24MHz and the [min,max] values for the PLL input if [10,320] MHz for ICST307 and [6,200] for ICST525, so the loop will always terminate immediately without assigning any divisor for the reference frequency. But for the code to make sense, let's insert the missing i++ Reported-by: David Binderman Signed-off-by: Linus Walleij Signed-off-by: Russell King Signed-off-by: Jiri Slaby --- arch/arm/common/icst.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/common/icst.c b/arch/arm/common/icst.c index 2dc6da70ae59..3b3e58b7ba74 100644 --- a/arch/arm/common/icst.c +++ b/arch/arm/common/icst.c @@ -58,6 +58,7 @@ icst_hz_to_vco(const struct icst_params *p, unsigned long freq) if (f > p->vco_min && f <= p->vco_max) break; + i++; } while (i < 8); if (i >= 8)