From patchwork Wed Jan 20 06:36:44 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hongbo Zhang X-Patchwork-Id: 60005 Delivered-To: patch@linaro.org Received: by 10.112.130.2 with SMTP id oa2csp2998833lbb; Tue, 19 Jan 2016 22:36:57 -0800 (PST) X-Received: by 10.140.99.5 with SMTP id p5mr41895228qge.76.1453271817591; Tue, 19 Jan 2016 22:36:57 -0800 (PST) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id 14si26888520qgg.18.2016.01.19.22.36.55; Tue, 19 Jan 2016 22:36:57 -0800 (PST) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dkim=neutral (body hash did not verify) header.i=@linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 85DCC6177C; Wed, 20 Jan 2016 06:36:55 +0000 (UTC) Authentication-Results: lists.linaro.org; dkim=fail reason="verification failed; unprotected key" header.d=linaro.org header.i=@linaro.org header.b=cftS/nVf; dkim-adsp=none (unprotected policy); dkim-atps=neutral X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, T_DKIM_INVALID, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id C9C7A616E7; Wed, 20 Jan 2016 06:36:49 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id C781261712; Wed, 20 Jan 2016 06:36:46 +0000 (UTC) Received: from mail-ob0-f173.google.com (mail-ob0-f173.google.com [209.85.214.173]) by lists.linaro.org (Postfix) with ESMTPS id 74AD9616BE for ; Wed, 20 Jan 2016 06:36:45 +0000 (UTC) Received: by mail-ob0-f173.google.com with SMTP id ba1so619146568obb.3 for ; Tue, 19 Jan 2016 22:36:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=ta/J0MR9TWiBDBUk1sBigvicjPi3Eemyt7rnQ4dED2c=; b=cftS/nVf859QPmC4ZqJ0u01yqF+EoMykNaWxNKyN1wd7locmj2w4KmiNppOuO5Rdfh TdXAEW6IWrk1lrS7DP939B57COKlvMyxJO9myiG8pVHZU7rwy5li5A2DCKKAo9ZuGb0c mRRObfrsx302Q20+OZ5Zt3h/nP498IbicJ2O0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=ta/J0MR9TWiBDBUk1sBigvicjPi3Eemyt7rnQ4dED2c=; b=DZideE95Mv6OPT/iy/vOfdtZFkBTMjg8cjWPKEWBlBURl420jD+9RP8zN3JUJoRKuA +P+Xpeo507jimi5wIAiGRokiQr5sBg/ccY5zuoBzYm7yf+/mgdjD5lD93R8NrJik8A1W xt1aHUxNtXOLMPBi66Ve56IvXoaV5vwq5b3zI0/IYBCT8+KIfBhXCRyATZ6k+lXG+vtS so1YvfMQEGxKa+iMjBqoRQZ4N+V9ksiqC/h2VaHXR1tauWGcJJbpUjn/B5pgpi33alon Mpm5Knyw4uIOt57GfrQf8gjrADRgbywUSlx3uIHu5yRcZR1U3WRCiookYgIcuiDYI65f uI7A== X-Gm-Message-State: AG10YOTq58VoG9NdaFnRPmnXVoRGaK3peqNA688QnxYCSygO/mp/6ZQG8nL4YPedI76wdxqQ5VHMsxu/VvgWcnNJQTc= MIME-Version: 1.0 X-Received: by 10.60.62.97 with SMTP id x1mr12902498oer.74.1453271805004; Tue, 19 Jan 2016 22:36:45 -0800 (PST) Received: by 10.202.172.80 with HTTP; Tue, 19 Jan 2016 22:36:44 -0800 (PST) In-Reply-To: <569E2FBB.4090209@linaro.org> References: <1453198633-24365-1-git-send-email-hongbo.zhang@linaro.org> <569E2FBB.4090209@linaro.org> Date: Wed, 20 Jan 2016 14:36:44 +0800 Message-ID: From: Hongbo Zhang To: Maxim Uvarov X-Topics: patch Cc: LNG ODP Mailman List Subject: Re: [lng-odp] [PATCH v6 API-NEXT 00/12] Separate CPU info codes into their platform files X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" This "WARNING: adding a line without newline at end of file" comes from patch 7: when adding new symlink in patch, there is such a warning, it is not an effective warning I think. Yes the symlink should be changed to ../linux/odp_cpu_arch.c I don't have full environment to verify codes of mips and powerpc, so I tested my odp_sysinfo_parse.c on my x86 platform this way: replace arch/x86/odp_sysinfo_parse.c with mips/odp_sysinfo_parse.c or powerpc/odp_sysinfo_parse.c, and let them to parse a fake /tmp/cpuinfo instead of /proc/cpuinfo, so I verified logic of my codes, but symlink compilation was missed. Will correct the symlink. On 19 January 2016 at 20:44, Maxim Uvarov wrote: > did you compile it for powerpc? > > there is wrong symlink. > > And also checkpatch warns about empty line at the end of file. > > Maxim. > > > On 01/19/2016 13:22, Hongbo Zhang wrote: >> >> There are still some checkpatch warnings of patches 6 and 7, but they >> should be due some defect of checkpatch.pl script and can be ignored I >> think. >> >> On 19 January 2016 at 18:17, wrote: >>> >>> From: Hongbo Zhang >>> >>> v5->v6 changes: >>> - eliminate checkpatch.pl warnings >>> >>> v4->v5 changes: >>> - rebase to latest api-next branch >>> >>> v3->v4 changes: >>> - update patch 9 of platform naming >>> - add new patch 12 to rename cpu_hz to cpu_hz_max >>> >>> v2->v3 changes: >>> use "api: cpu:" tag in patch 8/11 title instead of "linux-generic: >>> sysinfo" >>> >>> v1->v2 changes: >>> - don't create arch/arm/ since there isn't implementation now, use >>> arch/linux >>> as default choice >>> - create symlink to arch/linux/odp_cpu_cycles.c for powerpc, if absent >>> this >>> arch cannot be compiled >>> - add some clean-ups patches 8~11, these patches are against the >>> previous ones >>> so send them together for better review and merge. >>> >>> v1 notes: >>> This patch set separates the CPU info codes into their own platform >>> sepcific >>> files. >>> It is common sence that the top general layer call an uniform interface >>> to >>> initialize some plarform specific data structures, and this uniform >>> interface >>> is implemented in their own platform specific files. >>> This patch set makes it. >>> >>> Hongbo Zhang (12): >>> linux-generic: sysinfo: move cpu_arch_str to odp_system_info_t >>> linux-generic: sysinfo: use uniform call odp_sysinfo_parser >>> linux-generic: sysinfo: rename odp_cpu_hz_current with odp_ prefix >>> linux-generic: sysinfo: move x86 system info codes to its plarform >>> file >>> linux-generic: sysinfo: move MIPS system info codes to its plarform >>> file >>> linux-generic: sysinfo: move ARM system info codes to default arch >>> file >>> linux-generic: sysinfo: move PowerPC system info codes to its plarform >>> file >>> api: cpu: make frequency API return 0 on failure >>> linux-generic: sysinfo: set values for cpu_arch_str >>> linux-generic: sysinfo: apply per-CPU implementation to MIPS >>> linux-generic: sysinfo: apply per-CPU implementation to PowerPC >>> linux-generic: sysinfo: rename variable cpu_hz to cpu_hz_max >>> >>> configure.ac | 1 + >>> include/odp/api/cpu.h | 4 + >>> platform/linux-generic/Makefile.am | 10 +- >>> .../linux-generic/arch/linux/odp_sysinfo_parse.c | 19 ++ >>> .../linux-generic/arch/mips64/odp_sysinfo_parse.c | 64 ++++++ >>> platform/linux-generic/arch/powerpc/odp_cpu_arch.c | 1 + >>> .../linux-generic/arch/powerpc/odp_sysinfo_parse.c | 63 ++++++ >>> .../linux-generic/arch/x86/odp_sysinfo_parse.c | 73 +++++++ >>> platform/linux-generic/include/odp_internal.h | 7 +- >>> platform/linux-generic/odp_system_info.c | 220 >>> +-------------------- >>> 10 files changed, 245 insertions(+), 217 deletions(-) >>> create mode 100644 >>> platform/linux-generic/arch/linux/odp_sysinfo_parse.c >>> create mode 100644 >>> platform/linux-generic/arch/mips64/odp_sysinfo_parse.c >>> create mode 120000 platform/linux-generic/arch/powerpc/odp_cpu_arch.c >>> create mode 100644 >>> platform/linux-generic/arch/powerpc/odp_sysinfo_parse.c >>> create mode 100644 platform/linux-generic/arch/x86/odp_sysinfo_parse.c >>> >>> -- >>> 2.1.4 >>> >> _______________________________________________ >> lng-odp mailing list >> lng-odp@lists.linaro.org >> https://lists.linaro.org/mailman/listinfo/lng-odp > > > _______________________________________________ > lng-odp mailing list > lng-odp@lists.linaro.org > https://lists.linaro.org/mailman/listinfo/lng-odp --- /dev/null +++ b/platform/linux-generic/arch/powerpc/odp_cpu_arch.c @@ -0,0 +1 @@ +platform/linux-generic/arch/linux/odp_cpu_arch.c \ No newline at end of file