Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752720AbbBWINF (ORCPT ); Mon, 23 Feb 2015 03:13:05 -0500 Received: from mail-bn1on0112.outbound.protection.outlook.com ([157.56.110.112]:4386 "EHLO na01-bn1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752255AbbBWINB (ORCPT ); Mon, 23 Feb 2015 03:13:01 -0500 Message-ID: <54EAE0FA.3090402@freescale.com> Date: Mon, 23 Feb 2015 10:12:42 +0200 From: Purcareata Bogdan User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0 MIME-Version: 1.0 To: Sebastian Andrzej Siewior , Paolo Bonzini , Alexander Graf , Bogdan Purcareata , , CC: , , , Thomas Gleixner Subject: Re: [PATCH 0/2] powerpc/kvm: Enable running guests on RT Linux References: <1424251955-308-1-git-send-email-bogdan.purcareata@freescale.com> <54E73A6C.9080500@suse.de> <54E740E7.5090806@redhat.com> <54E74A8C.30802@linutronix.de> <54E74B58.90706@redhat.com> <54E74D5E.1050209@linutronix.de> <54E74E77.2070503@redhat.com> <54E74FED.2090203@linutronix.de> In-Reply-To: <54E74FED.2090203@linutronix.de> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [192.88.166.1] X-ClientProxiedBy: DB4PR02CA0025.eurprd02.prod.outlook.com (10.242.174.153) To BN1PR03MB185.namprd03.prod.outlook.com (10.255.200.139) Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=B43198@freescale.com; X-Microsoft-Antispam: UriScan:; X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:;SRVR:BN1PR03MB185; X-Bulk-Sender: Mark as legitimate X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(5005003);SRVR:BN1PR03MB185; X-Forefront-PRVS: 0496DF6962 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(6049001)(6009001)(51704005)(199003)(24454002)(377454003)(479174004)(189002)(101416001)(59896002)(62966003)(2950100001)(105586002)(40100003)(77096005)(50466002)(36756003)(93886004)(42186005)(23746002)(33656002)(68736005)(86362001)(77156002)(46102003)(83506001)(65806001)(65956001)(65816999)(87976001)(47776003)(76176999)(66066001)(64706001)(80316001)(106356001)(92566002)(50986999)(54356999)(122386002)(97736003)(87266999)(2201001)(64126003)(2101003)(42262002);DIR:OUT;SFP:1102;SCL:1;SRVR:BN1PR03MB185;H:[10.171.74.27];FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:;SRVR:BN1PR03MB185; X-OriginatorOrg: freescale.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Feb 2015 08:12:57.2245 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN1PR03MB185 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2319 Lines: 59 On 20.02.2015 17:17, Sebastian Andrzej Siewior wrote: > On 02/20/2015 04:10 PM, Paolo Bonzini wrote: >> On 20/02/2015 16:06, Sebastian Andrzej Siewior wrote: >>> On 02/20/2015 03:57 PM, Paolo Bonzini wrote: >> >>>> Yes, but large latencies just mean the code has to be rewritten (x86 >>>> doesn't anymore do event injection in an atomic regions for example). >>>> Until it is, using raw_spin_lock is correct. >>> >>> It does not sound like it. It sounds more like disabling interrupts to >>> get things run faster and then limit it on a different corner to not >>> blow up everything. >> >> "This patchset enables running KVM SMP guests with external interrupts >> on an underlying RT-enabled Linux. Previous to this patch, a guest with >> in-kernel MPIC emulation could easily panic the kernel due to preemption >> when delivering IPIs and external interrupts, because of the openpic >> spinlock becoming a sleeping mutex on PREEMPT_RT_FULL Linux". >> >>> Max latencies was decreased "Max latency (us) 70 62" and that >>> is why this is done? For 8 us and possible DoS in case there are too >>> many cpus? >> >> My understanding is that: >> >> 1) netperf can get you a BUG KVM, and raw_spinlock fixes that Actually, it's not just netperf. The bug triggers in the following scenarios: - running CPU intensive task (while true; do date; done) in SMP guest (even with 2 VCPUs) - running netperf in guest - running cyclictest in SMP guest > May I please see a backtrace with context tracking which states where > the interrupts / preemption gets disabled and where the lock was taken? Will do, I will get back to you as soon as I have it available. I will try and capture it using function trace. > I'm not totally against this patch I just want to make sure this is not > a blind raw conversation to shup up the warning the kernel throws. > >> 2) cyclictest did not trigger the BUG, and you can also get reduced >> latency from using raw_spinlock. >> >> I think we agree that (2) is not a factor in accepting the patch. > good :) > >> >> Paolo >> > Sebastian > -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/