From patchwork Mon Oct 15 13:06:32 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chander Kashyap X-Patchwork-Id: 191559 X-Patchwork-Delegate: promsoft@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 6F8DE2C0087 for ; Tue, 16 Oct 2012 00:07:04 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 9C29D4A051; Mon, 15 Oct 2012 15:07:01 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id JUuCSZhOzXXD; Mon, 15 Oct 2012 15:07:01 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id C3B7B4A053; Mon, 15 Oct 2012 15:06:57 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 2B7C84A053 for ; Mon, 15 Oct 2012 15:06:54 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id WbAtGmKK+FJ7 for ; Mon, 15 Oct 2012 15:06:52 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-pb0-f44.google.com (mail-pb0-f44.google.com [209.85.160.44]) by theia.denx.de (Postfix) with ESMTPS id A07284A051 for ; Mon, 15 Oct 2012 15:06:48 +0200 (CEST) Received: by mail-pb0-f44.google.com with SMTP id ro8so4908224pbb.3 for ; Mon, 15 Oct 2012 06:06:45 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:x-gm-message-state; bh=oS5cqozwN+/Ze1ojw9t92AtB9O68BEHsPZSAf+v2S8s=; b=PW6K25HebrEveaQdkyWDxvKNcTmJ2yi/E4XXow7gfZQBUSAftKjZFFSXwTJkOS3Au7 1+0x0n8GG/icVp9K1alxmJRNsJ8j3sqwz7nU5NdlToIiIojKhHrGjVmvpOKg2GuTaIRE pLJNhD77lp46HB/w1AyjTO12KoXKwNzNj/F2XPmPtecdP3/I8aj//YbT0oIgTue2w3vb uZcutl7BHC4JpxIPQvsfH+qnlenNpeGTABLOgXSAWhDtOEXsZ7f+rfzIK7Z6h4ubRX1c iB9EI5YoTNBAMenIZP9JwGDwr69qOVqxBSkZTJ083IpsaN0E46dBInReEv8FSqvPG3MX 2g+A== Received: by 10.68.190.197 with SMTP id gs5mr37509707pbc.124.1350306405061; Mon, 15 Oct 2012 06:06:45 -0700 (PDT) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id pw2sm9046080pbb.59.2012.10.15.06.06.42 (version=SSLv3 cipher=OTHER); Mon, 15 Oct 2012 06:06:44 -0700 (PDT) From: Chander Kashyap To: u-boot@lists.denx.de Date: Mon, 15 Oct 2012 18:36:32 +0530 Message-Id: <1350306392-5273-1-git-send-email-chander.kashyap@linaro.org> X-Mailer: git-send-email 1.7.9.5 X-Gm-Message-State: ALoCoQnDGeuuWDYghotk+AcX87VrfLJt+48YfKOI8IkikYweyNi0iR9Pvlyv5OvJp5F9BgNb2+Sb Cc: linaro-dev@lists.linaro.org, patches@linaro.org Subject: [U-Boot] [PATCH v3] ARCH: EXYNOS: add support to match product id X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de From: Minkyu Kang Based upon single SoC there can be multiple variants. This patch add support to match the complete product ID. Signed-off-by: Chander Kashyap --- Changes from v1: - Author name changed Changes from v2: - Fixed typo 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) \ { \