From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757170AbcIHIYU (ORCPT ); Thu, 8 Sep 2016 04:24:20 -0400 Received: from Galois.linutronix.de ([146.0.238.70]:42728 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754213AbcIHIYS (ORCPT ); Thu, 8 Sep 2016 04:24:18 -0400 Date: Thu, 8 Sep 2016 10:21:34 +0200 (CEST) From: Thomas Gleixner To: Fenghua Yu cc: "H. Peter Anvin" , Ingo Molnar , Tony Luck , Peter Zijlstra , Tejun Heo , Borislav Petkov , Stephane Eranian , Marcelo Tosatti , David Carrillo-Cisneros , Shaohua Li , Ravi V Shankar , Vikas Shivappa , Sai Prakhya , linux-kernel , x86 Subject: Re: [PATCH v2 04/33] drivers/base/cacheinfo.c: Export some cacheinfo functions for others to use In-Reply-To: <1473328647-33116-5-git-send-email-fenghua.yu@intel.com> Message-ID: References: <1473328647-33116-1-git-send-email-fenghua.yu@intel.com> <1473328647-33116-5-git-send-email-fenghua.yu@intel.com> User-Agent: Alpine 2.20 (DEB 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 8 Sep 2016, Fenghua Yu wrote: > From: Fenghua Yu > > We use ci_cpu_cacheinfo in CAT. Export this function for CAT to reuse. So ci_cpu_cacheinfo is a function? AFAICT it's a struct. > +#define ci_cacheinfo(cpu) (&per_cpu(ci_cpu_cacheinfo, cpu)) Why a define and not an inline? &per_cpu should be per_cpu_ptr .... And a define is not a function either and certainly that whole thing has nothing to do with an export. Furthermore $subject talks about some functions. I still have to see one. It's an art to get a onliner patch screwed up in more than one way so badly. No bisquit! tglx