From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753672AbcENPb0 (ORCPT ); Sat, 14 May 2016 11:31:26 -0400 Received: from www.linutronix.de ([62.245.132.108]:60036 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752304AbcENPbZ (ORCPT ); Sat, 14 May 2016 11:31:25 -0400 Date: Sat, 14 May 2016 17:29:41 +0200 (CEST) From: Thomas Gleixner To: Xie XiuQi cc: hch@infradead.org, linux-kernel@vger.kernel.org, huawei.libin@huawei.com, wangyijing@huawei.com Subject: Re: [PATCH] genirq: export __irq_set_affinity symbol In-Reply-To: <57346C0D.8020706@huawei.com> Message-ID: References: <1463032287-21692-1-git-send-email-xiexiuqi@huawei.com> <57346C0D.8020706@huawei.com> User-Agent: Alpine 2.11 (DEB 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Linutronix-Spam-Score: -1.0 X-Linutronix-Spam-Level: - X-Linutronix-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1,SHORTCIRCUIT=-0.0001 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 12 May 2016, Xie XiuQi wrote: > On 2016/5/12 15:43, Thomas Gleixner wrote: > > On Thu, 12 May 2016, Xie XiuQi wrote: > > > >> __irq_set_affinity is declared in include/linux/interrupt.h, but not > >> been exported. > >> > >> We export it now, so we could use __irq_set_affinity, irq_set_affinity > >> and irq_force_affinity in kernel modules. > > > > Please show the code using the exports first. We don't export symbols w/o > > knowing the usecase. > > The default affinity of the interrupts for all devices is always CPU0, > this may cause the latency on CPU0 is very high when some interrupt > occurs very frequently. > > I want to migrate an interrupt to another cpu when the driver loading. What's wrong with setting the affinity from user space? > My code like this: > > /* I want to bind irq_vector to cpu 3 */ And that CPU 3 is hard coded into the driver? That's just wrong. Thanks, tglx