From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30883 invoked by alias); 27 Jun 2008 14:41:13 -0000 Received: (qmail 30870 invoked by uid 22791); 27 Jun 2008 14:41:12 -0000 X-Spam-Status: No, hits=0.7 required=5.0 tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_PASS X-Spam-Check-By: sourceware.org Received: from hs-out-0708.google.com (HELO hs-out-0708.google.com) (64.233.178.247) by sourceware.org (qpsmtpd/0.31) with ESMTP; Fri, 27 Jun 2008 14:40:55 +0000 Received: by hs-out-0708.google.com with SMTP id 55so258696hsc.14 for ; Fri, 27 Jun 2008 07:40:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:mime-version:content-type:content-transfer-encoding :content-disposition; bh=DlZqS45n+r0MeDDkD4u890UTG4kTd4z0S4L3tQK9BZ8=; b=L3bQmlNBJVKoy/ttp62JVbyBRvlPGH5HQ8rMVGtXr4wcDpmOHK+o+z+IS5LXMkvNw1 0dfCSHQf1Ta2m8JKHdfBVtsaNQN9JDaugQIrvTgXrzZVG2wnl1jOslUnhBIsjBTKVT4S WRliRS25h6pdlRJX+hDjuJVnCqlmvfXKn9RwM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:mime-version:content-type :content-transfer-encoding:content-disposition; b=GZI6fdN0qp8UyUsueb2tAL96XT8sxW4iP4nks8Y+T5BAqfNzwGFfKJH38p2n7m0khh H9B0yPrIAYoNhJ7axk1j9ifz7PR5MvQtd9Uji6ECItLzijHmJ7GIuzKxcjQfWnuEFHKO GeZKheVROinbatksnk+deN5/ix2GA+gILwjPg= Received: by 10.150.227.14 with SMTP id z14mr2338392ybg.145.1214577650610; Fri, 27 Jun 2008 07:40:50 -0700 (PDT) Received: by 10.150.95.17 with HTTP; Fri, 27 Jun 2008 07:40:44 -0700 (PDT) Message-ID: <111ced750806270740k430d9ca9we3f3f1bd84d65ab7@mail.gmail.com> Date: Fri, 27 Jun 2008 14:41:00 -0000 From: "Davy Wouters" To: ecos-devel@ecos.sourceware.org Subject: New hal port + interrupts + rescheduling + call_pending_dsrs problem MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline 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: 2008-06/txt/msg00039.txt.bz2 Hi all, I have done a hal port to the Analog Devices Blackfin processor starting from the latest from cvs version of ecos. I don't quite understand how the interrupt handling in default_interrupt_vsr works. When an interrupt occurs from my uart, i have a interrupt trampoline which does some vector translation and then calls the hal_interrupt_default_vsr which calls the isr of my uart rx interrupt. This isr requests a dsr to run. I have made the hal_interrupt_default_vsr as instructed ending with the interrupt_end call from the interrupt object of the kernel. One of the problems i seem to have is that call_pending_dsrs is called (from within interrupt_end - scheduler::unlock_inner) while the processor is still running at the interrupt level of my uart. (Nested interrupts are disabled, no separate interrupt stack is used) I assume a return from interrupt should be executed somewhere between the execution of the isr/post_dsr and the call_pending_dsrs? Where would this be done, in other words at which point in the hal do i need to return from my interrupt? Is it correct that call_pending_dsrs should be executed only when other interrupts are allowed again, in other words after return from the interrupt? Sorry if my questions are a bit confusing, but i don't quite understand the problems i'm having at this point (Crashes when having a lot of communication on my uart rx resulting in ASSERT_FAIL: <6>mutex.cxx[249]cyg_bool Cyg_Mutex::lock() Locking mutex I already own) Any suggestions? Tnx, Davy Wouters Atos engineering