Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1760070AbXLTUN4 (ORCPT ); Thu, 20 Dec 2007 15:13:56 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1759833AbXLTUMq (ORCPT ); Thu, 20 Dec 2007 15:12:46 -0500 Received: from mga06.intel.com ([134.134.136.21]:47276 "EHLO orsmga101.jf.intel.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1759798AbXLTUMo (ORCPT ); Thu, 20 Dec 2007 15:12:44 -0500 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.24,191,1196668800"; d="scan'208";a="301985351" Message-ID: <476ACABC.4010503@linux.intel.com> Date: Thu, 20 Dec 2007 21:04:12 +0100 From: Arjan van de Ven User-Agent: Thunderbird 1.5 (Windows/20051201) MIME-Version: 1.0 To: Parag Warudkar CC: "Kok, Auke" , Stephen Hemminger , netdev@vger.kernel.org, akpm@linux-foundation.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] sky2: Use deferrable timer for watchdog References: <20071220091603.0d69b045@deepthought> <823114761-1198171803-cardhu_decombobulator_blackberry.rim.net-937108990-@bxe019.bisx.prod.on.blackberry> <20071220095121.7859c023@deepthought> <476ABDDF.8080607@intel.com> <476ABE7D.60901@linux.intel.com> <476AC105.9090206@intel.com> <82e4877d0712201200h7b994175u841d1efa047cefff@mail.gmail.com> In-Reply-To: <82e4877d0712201200h7b994175u841d1efa047cefff@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2266 Lines: 48 Parag Warudkar wrote: > On Dec 20, 2007 2:22 PM, Kok, Auke wrote: >> ok, that's just bad and if there's no user-defineable limit to the deferral I >> definately don't like this change. >> >> Can I safely assume that any irq will cause all deferred timers to run? > > I think even other causes for wakeup like process related ones will > cause the CPU to go busy and run the timers. > This, coupled with the fact that no one is yet able to reach 0 wakeups > per second makes it pretty unlikely that deferrable timers will be > deferred indefinitely. 0.8 is easy on single core today. multicore just increases how idle you can be for a given core. > >> If this is the case then for e1000 this patch is still OK since the watchdog needs >> to run (1) after a link up/down interrupt or (2) to update statistics. Those >> statistics won't increase if there is no traffic of course... >> > > I think it is reasonable for Network driver watchdogs to use a > deferrable timer - if the machine is 100% IDLE there is no one needing > the network to be up. If there is something running even on the other > CPU - that is going to cause an IPI, reschedule, TLB invalidation etc. > which will make it very likely in practice that each CPU will be > interrupted in reasonable amount of time. this is not correct; many machines are idle waiting for network data. Think of webservers... > > Of course there are theoretical cases where we could land into a > situation where a CPU in a multiprocessor machine is IDLE infinitely > and that causes the watchdog that happens to be bound to run on the > same CPU to not run. To take care of these unlikely cases I think the > timer mechanism should have a reasonable limit on how long a CPU can > go IDLE if there are deferrable timers. how about something else instead: a timer mechanism that takes a range instead.. that at least has defined semantics; the deferrable semantics really are "indefinite". Lets keep at least the semantics clear and clean. -- 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/