EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

2002  2003  2004  2005  <20062007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024  Index 2002  2003  2004  2005  <20062007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
<== Date ==> <== Thread ==>

Subject: RE: osiSockDiscoverBroadcastAddresses(): pointer not word-aligned?
From: "Jeff Hill" <[email protected]>
To: "'Eric Norum'" <[email protected]>, "'Ralph Lange'" <[email protected]>
Cc: "'EPICS Core Talk'" <[email protected]>, "'Ralf Hartmann'" <[email protected]>
Date: Thu, 24 Aug 2006 15:08:53 -0600

> Jeff: should I commit that (double buffer) patch to the APS repository for 3.14 and the trunk?

> Or send it to you first?

 

Yes please, go ahead with a commit. I will try to have a very quick look after you are done. No doubt that you have been careful about freeing anything that gets allocated.

 

> The CA data garble issue was solved by applying the patch from Peter Denison. Do you want me to

> commit that, too?

 

Here are some of the issues that I seem to recall should be looked at.

 

O I think that there were a few spots in the source that were missed by them that might not be observed as failures in an IOC but might still come up (maybe only in the portable server).

 

O It would be nice to consolidate the hardware architecture specific stuff into one place in the source code.

 

O We would like to configure the software based on the endian type macros, and set these macros from the configure files based on the hardware architecture type so we don’t end up with an endless proliferation of ifdef test cases, but perhaps this has been attended to already.

 

O maybe others - I should have a closer look

 

I had concluded that this work could be postponed until we get serious about another patch release, but perhaps my procrastination is causing some grief in terms of duplicated work. It seems that more folks are using ARM processors than I initially expected.

 

Jeff

 


From: Eric Norum [mailto:[email protected]]
Sent: Thursday, August 24, 2006 10:26 AM
To: Ralph Lange
Cc: Jeff Hill; 'EPICS Core Talk'; 'Ralf Hartmann'
Subject: Re: osiSockDiscoverBroadcastAddresses(): pointer not word-aligned?

 

Great detective work!

I did a quick google check and it seems that SIOCGIFCONF is not a very well defined operation. Your plan to copy to a properly aligned local buffer sounds good to me.

 

 

On Aug 24, 2006, at 11:07 AM, Ralph Lange wrote:



OK - here are our latest findings:

 

First - the Bottom line: The RTEMS network code does not work as expected. Calling socket_ioctl() with SIOCGIFCONF does return also AF_LINK structures, not just AF_INET interfaces, as the linux man page says.

 

.......

 

We are suggesting to keep the double buffer: memcpy()ing whatever is coming up into a local buffer which is word-aligned, and handing a pointer to that copy down in subsequent socket_ioctl() calls. This doesn't use much space and time and should be safe - no matter what is coming up in the ifreq array. osiSockDiscoverBroadcastAddresses() isn't called much anyway.

 

Jeff: should I commit that patch to the APS repository for 3.14 and the trunk? Or send it to you first?

 

The CA data garble issue was solved by applying the patch from Peter Denison. Do you want me to commit that, too?

 

Thanks again to both of you for your valuable help!!

Ralph & Ralf

 

 

--

Eric Norum <[email protected]>

Advanced Photon Source

Argonne National Laboratory

(630) 252-4793



 


References:
Re: osiSockDiscoverBroadcastAddresses(): pointer not word-aligned? Eric Norum

Navigate by Date:
Prev: Re: osiSockDiscoverBroadcastAddresses(): pointer not word-aligned? Eric Norum
Next: Changes for RTEMS on ARM (at91rm9200ek) Ralph Lange
Index: 2002  2003  2004  2005  <20062007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
Navigate by Thread:
Prev: Re: osiSockDiscoverBroadcastAddresses(): pointer not word-aligned? Eric Norum
Next: Changes for RTEMS on ARM (at91rm9200ek) Ralph Lange
Index: 2002  2003  2004  2005  <20062007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  2022  2023  2024 
ANJ, 02 Feb 2012 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·