From patchwork Tue Oct 2 09:50:43 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chander Kashyap X-Patchwork-Id: 11912 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 959B023E42 for ; Tue, 2 Oct 2012 09:51:03 +0000 (UTC) Received: from mail-ie0-f180.google.com (mail-ie0-f180.google.com [209.85.223.180]) by fiordland.canonical.com (Postfix) with ESMTP id 3F167A18499 for ; Tue, 2 Oct 2012 09:51:03 +0000 (UTC) Received: by ieje10 with SMTP id e10so13712733iej.11 for ; Tue, 02 Oct 2012 02:51:02 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:x-gm-message-state; bh=jIFa4jtVzTWrZTNBtwH7tOrnquzF6J98TEnCG4E92Ts=; b=n49H4U3/IrH5Tu0ggXXUdPRz+VRgqtv5I9NhxahxPxbjmPttvj1xS995K7w1Fza6i/ gspa6fiQyzsnGCrKYJAmZZRvLlcsfeMbvixzciv1BHNhabsqP6sGbbZTt5zckoWiqNCG GqJgre3boGH+N/aDJkImr2e8r5epLkgw95/fYdHS/dIeBhiAdmmfn5FU5EAtt0d6GhZV ZYQRl28BFsDeDS3R+FP8+nzlzpVpAkDtADF4PC0mIV56n5ps4uyClGQuKU/v+z7XSFgs nPlJVYwb1liFO8ASQpeFhEr42TW7YV0hf4A0jAgrhy97IMCbZrPld3vvkD8VTbYLZrzT hiWg== Received: by 10.42.110.130 with SMTP id q2mr13383703icp.53.1349171462480; Tue, 02 Oct 2012 02:51:02 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.50.184.232 with SMTP id ex8csp72857igc; Tue, 2 Oct 2012 02:51:01 -0700 (PDT) Received: by 10.68.203.195 with SMTP id ks3mr2875218pbc.79.1349171461482; Tue, 02 Oct 2012 02:51:01 -0700 (PDT) Received: from mail-da0-f50.google.com (mail-da0-f50.google.com [209.85.210.50]) by mx.google.com with ESMTPS id pv1si1193999pbb.119.2012.10.02.02.51.00 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 02 Oct 2012 02:51:01 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.210.50 is neither permitted nor denied by best guess record for domain of chander.kashyap@linaro.org) client-ip=209.85.210.50; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.210.50 is neither permitted nor denied by best guess record for domain of chander.kashyap@linaro.org) smtp.mail=chander.kashyap@linaro.org Received: by daez20 with SMTP id z20so2191166dae.37 for ; Tue, 02 Oct 2012 02:51:00 -0700 (PDT) Received: by 10.68.190.233 with SMTP id gt9mr2744794pbc.137.1349171460243; Tue, 02 Oct 2012 02:51:00 -0700 (PDT) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id qd6sm673395pbb.34.2012.10.02.02.50.57 (version=SSLv3 cipher=OTHER); Tue, 02 Oct 2012 02:50:59 -0700 (PDT) From: Chander Kashyap To: u-boot@lists.denx.de Cc: mk7.kang@samsung.com, linaro-dev@lists.linaro.org, patches@linaro.org, Chander Kashyap , Chander Kashyap Subject: [PATCH] ARCH: EXYNOS: add support to match product id Date: Tue, 2 Oct 2012 15:20:43 +0530 Message-Id: <1349171443-13624-1-git-send-email-chander.kashyap@linaro.org> X-Mailer: git-send-email 1.7.9.5 X-Gm-Message-State: ALoCoQm60Y6jQKebNKYuPX/jwg7krFCfkA1qlrBWEm01yDHb/F09OppZG8m2k1wMewcrMQnHp8sE From: Chander Kashyap Based upon single SoC there can be multiple varients. This patch add support to match the complete product ID. Signed-off-by: Chander Kashyap --- arch/arm/include/asm/arch-exynos/cpu.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/arch/arm/include/asm/arch-exynos/cpu.h b/arch/arm/include/asm/arch-exynos/cpu.h index 2cd4ae1..2bde10c 100644 --- a/arch/arm/include/asm/arch-exynos/cpu.h +++ b/arch/arm/include/asm/arch-exynos/cpu.h @@ -139,6 +139,15 @@ static inline int cpu_is_##type(void) \ IS_SAMSUNG_TYPE(exynos4, 0x4) IS_SAMSUNG_TYPE(exynos5, 0x5) +#define IS_EXYNOS_TYPE(type, id) \ +static inline int proid_is_##type(void) \ +{ \ + return s5p_cpu_id == id; \ +} + +IS_EXYNOS_TYPE(exynos4210, 0x4210) +IS_EXYNOS_TYPE(exynos5250, 0x5250) + #define SAMSUNG_BASE(device, base) \ static inline unsigned int samsung_get_base_##device(void) \ { \