From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20867 invoked by alias); 18 Jan 2012 21:48:53 -0000 Received: (qmail 20859 invoked by uid 22791); 18 Jan 2012 21:48:52 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from hagrid.ecoscentric.com (HELO mail.ecoscentric.com) (212.13.207.197) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 18 Jan 2012 21:48:39 +0000 Received: from localhost (hagrid.ecoscentric.com [127.0.0.1]) by mail.ecoscentric.com (Postfix) with ESMTP id 45BD42F78008 for ; Wed, 18 Jan 2012 21:48:38 +0000 (GMT) Received: from mail.ecoscentric.com ([127.0.0.1]) by localhost (hagrid.ecoscentric.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 9jEAve7pB+TX; Wed, 18 Jan 2012 21:48:37 +0000 (GMT) From: bugzilla-daemon@bugs.ecos.sourceware.org To: ecos-patches@ecos.sourceware.org Subject: [Bug 1001453] CAN IO package: wider flags field, flag to report return to 'error active' mode X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: eCos X-Bugzilla-Component: Patches and contributions X-Bugzilla-Keywords: X-Bugzilla-Severity: enhancement X-Bugzilla-Who: bernard.fouche@kuantic.com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: low X-Bugzilla-Assigned-To: unassigned@bugs.ecos.sourceware.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: In-Reply-To: References: X-Bugzilla-URL: http://bugs.ecos.sourceware.org/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Date: Wed, 18 Jan 2012 21:48:00 -0000 Message-Id: <20120118214836.DF3952F78004@mail.ecoscentric.com> Mailing-List: contact ecos-patches-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: ecos-patches-owner@ecos.sourceware.org X-SW-Source: 2012-01/txt/msg00060.txt.bz2 Please do not reply to this email. Use the web interface provided at: http://bugs.ecos.sourceware.org/show_bug.cgi?id=3D1001453 --- Comment #7 from Bernard Fouch=C3=A9 2012-0= 1-18 21:48:30 GMT --- Yet more needed change: - since flags will be 32 bits wide, then the flag_mask field in cyg_can_callback_cfg_st must be expanded too. Must do a typedef (or a #defi= ne?) for flags instead of using cyg_uint32, I missed the flag_mask expansion bec= ause of this. - in can_callbacks_t, describing the function pointers accessible to the low level drivers, xmt_msg is today: void (*xmt_msg)(can_channel *chan, void *pdata) I'd like to have instead: cyg_bool (*xmt_msg)(can_channel *chan, void *pdata) This is because when the low level driver knows that it can send more than = one message, it has no way to know if high level Tx queue is empty or not. For instance the driver I test now uses the 3 TX buffers of the LPC17XX. When X buffers are free, the driver can just call X times xmt_msg, even if no mess= age is queued. Proposed changed is to have xmt_msg to report is a message was s= ent when it was called. If yes, then call again xmt_msg if there are still free= Tx buffers. If no, stop calling since it's useless. On hardware supporting many Message Objects this need will arise anyway. The only other possibility is = to use a global variable in the low level driver: reset the variable, call xmt_msg() that calls driver _putmsg(), set variable there, go back to DSR, = test variable. Seems ugly an inefficient. There are other issues: - autobaud is said to be potentially supported by the CAN IO package, but t= here is no infrastructure to manage it. I hardly see how it could without some parameters defining the set of speeds to try, how long to wait for a timeout,and how to warn the upper layer that autobaud found some speed (no event like CYGNUM_CAN_EVENT_AUTOBAUD_END exists). No start/stop autobaud co= nfig keys exist.=20=20=20 - LPC2XXX driver supports listen-only mode also by providing unofficial con= fig keys. IMHO they should be made mainstream since this feature is more and mo= re available and is very handy, for instance to make a non-intrusive network monitor (and eventually autobaud...).=20 - the application can't know the current values of TX/RX Rec while these are important to diagnose a bus. A _get_config() key seems appropriate. BTW I start tomorrow a few days of field tests, I'll try to make an updated patch next week. Bernard --=20 Configure bugmail: http://bugs.ecos.sourceware.org/userprefs.cgi?tab=3Demail ------- You are receiving this mail because: ------- You are on the CC list for the bug.