From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26921 invoked by alias); 3 May 2011 07:04:01 -0000 Received: (qmail 26907 invoked by uid 22791); 3 May 2011 07:03:59 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,RFC_ABUSE_POST X-Spam-Check-By: sourceware.org Received: from mail-vx0-f169.google.com (HELO mail-vx0-f169.google.com) (209.85.220.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 03 May 2011 07:03:45 +0000 Received: by vxk20 with SMTP id 20so6194382vxk.0 for ; Tue, 03 May 2011 00:03:44 -0700 (PDT) MIME-Version: 1.0 Received: by 10.52.74.68 with SMTP id r4mr1442795vdv.8.1304406224635; Tue, 03 May 2011 00:03:44 -0700 (PDT) Received: by 10.52.110.230 with HTTP; Tue, 3 May 2011 00:03:44 -0700 (PDT) In-Reply-To: <4DBFA2E4.3040603@televic.com> References: <4DBFA2E4.3040603@televic.com> Date: Tue, 03 May 2011 07:04:00 -0000 Message-ID: Subject: Re: [ECOS] Miss calling ASR in sched.cxx From: Huang Yi To: =?ISO-8859-1?Q?J=FCrgen_Lambrecht?= Cc: ecos-devel@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact ecos-devel-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: ecos-devel-owner@ecos.sourceware.org X-SW-Source: 2011-05/txt/msg00002.txt.bz2 Thanks. But at the mail archive, I found my original mail : http://ecos.sourceware.org/ml/ecos-devel/2011-04/msg00008.html The patch is present at the end of the mail. I paste the same patch text here: ------------------------------[PATCH START] -------------------------------= ----- Index: packages/kernel/current/src/sched/sched.cxx =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /cvs/ecos/ecos/packages/kernel/current/src/sched/sched.cxx,v retrieving revision 1.20 diff -u -8 -p -r1.20 sched.cxx --- packages/kernel/current/src/sched/sched.cxx 29 Jan 2009 17:49:50 -0000 1.20 +++ packages/kernel/current/src/sched/sched.cxx 22 Apr 2011 02:42:06 -0000 @@ -131,16 +131,20 @@ inline void *operator new(size_t size, v // have when it reschedules this thread back, and leaves this function. // When it is non-zero, and the thread is rescheduled, no ASRS are run, // or DSRs processed. By doing this, it makes it possible for threads // that want to go to sleep to wake up with the scheduler lock in the // same state it was in before. void Cyg_Scheduler::unlock_inner( cyg_ucount32 new_lock ) { +#ifdef CYGSEM_KERNEL_SCHED_ASR_SUPPORT + cyg_bool call_asr =3D false; +#endif + #ifdef CYGDBG_KERNEL_TRACE_UNLOCK_INNER CYG_REPORT_FUNCTION(); #endif do { CYG_PRECONDITION( new_lock=3D=3D0 ? get_sched_lock() =3D=3D 1 : ((get_sched_lock() =3D=3D new_lock) || (get_sched_lock() =3D=3D new_lock+1)), @@ -229,23 +233,21 @@ void Cyg_Scheduler::unlock_inner( cyg_uc } if( new_lock =3D=3D 0 ) { #ifdef CYGSEM_KERNEL_SCHED_ASR_SUPPORT // Check whether the ASR is pending and not inhibited. If - // we can call it, then transfer this info to a local + // we can call it, then transfer this info to a // variable (call_asr) and clear the pending flag. Note // that we only do this if the scheduler lock is about to // be zeroed. In any other circumstance we are not // unlocking. - - cyg_bool call_asr =3D false; if( (current->asr_inhibit =3D=3D 0) && current->asr_pending ) { call_asr =3D true; current->asr_pending =3D false; } #endif ------------------------------[PATCH END] ---------------------------------= --- 2011/5/3 J=FCrgen Lambrecht : > This is the correct list, but your attachment got lost. > Regards, J=FCrgen --=20 Huang Yi (kiron) -------------------