Hi Jakob,

I submitted a patch that fixes the include guard bug so you don't have
to do anything with it. We can work together to get your work sorted
out and merged, kindly let us know if you need any help.

Best,
Hesham

On Wed, Mar 2, 2016 at 5:01 PM, Hesham Almatary
<heshamelmat...@gmail.com> wrote:
> Hi Jakob,
>
> I reapplied your patches after the include guard issue and it compiles
> fine. However, helloworld and ticker samples don't work on either
> or1ksim or qemu. Both run fine without your patches applied. Since not
> all the users have a hardware platform, RTEMS prefers that each port
> runs at least hello and ticker on one or more simulators. So it would
> be great if you can test your patches on or1ksim and/or qemu as the
> main targets for testing.
>
> There's a readme file at the generic_or1k directory that contains some
> instructions how to run the test cases. Also, RTEMS has two other
> systems for testing purposes like sim-scripts [1] which has scripts to
> run test cases, and RTEMS Tester [2] that automates running the whole
> 500+ tests. or1k port within RTEMS Tester depends on qemu-system-or32
> and not or1ksim.
>
> I'd be happy to provide any help if required.
>
> [1] https://devel.rtems.org/browser/rtems-testing/sim-scripts
> [2] https://devel.rtems.org/wiki/Testing/Tester
>
> Best,
> Hesham
>
> On Wed, Mar 2, 2016 at 11:44 AM, Hesham Almatary
> <heshamelmat...@gmail.com> wrote:
>> On Tue, Mar 1, 2016 at 2:03 PM, Jakob Viketoft
>> <jakob.viket...@aacmicrotec.com> wrote:
>>> ________________________________________
>>> From: devel [devel-boun...@rtems.org] on behalf of Hesham Almatary 
>>> [heshamelmat...@gmail.com]
>>> Sent: Saturday, February 27, 2016 19:57
>>> To: Jakob Viketoft
>>> Cc: rtems-de...@rtems.org
>>> Subject: Re: [PATCH 5/8] generic_or1k BSP clock driver correction
>>>
>>>>On Sat, Feb 20, 2016 at 11:01 PM,  <jakob.viket...@gmail.com> wrote:
>>>>> From: Jakob Viketoft <jakob.viket...@aacmicrotec.com>
>>>>>
>>>>>  - Improve the clock driver to use RTEMS default tick period
>>>>>    or the on the one supplied by the application
>>>>>  - Avoid rewriting the timer settings, since all we need is to clear the 
>>>>> interrupt
>>>>>  - Remove any mention of or1ksim in favour of generic_or1k
>>>>>
>>>>> Close #2600
>>>>> ---
>>>>>  .../lib/libbsp/or1k/generic_or1k/clock/clockdrv.c  | 109 
>>>>> ++++++++++-----------
>>>>>  1 file changed, 51 insertions(+), 58 deletions(-)
>>>>>
>>>>> diff --git a/c/src/lib/libbsp/or1k/generic_or1k/clock/clockdrv.c 
>>>>> b/c/src/lib/libbsp/or1k/generic_or1k/clock/clockdrv.c
>>>>> index e01d2e5..60eec98 100644
>>>>> --- a/c/src/lib/libbsp/or1k/generic_or1k/clock/clockdrv.c
>>>>> +++ b/c/src/lib/libbsp/or1k/generic_or1k/clock/clockdrv.c
>>>>> @@ -3,13 +3,15 @@
>>>>>   *
>>>>>   * @ingroup bsp_clock
>>>>>   *
>>>>> - * @brief or1k clock support.
>>>>> + * @brief generic_or1k clock support.
>>>>>   */
>>>>>
>>>>>  /*
>>>>>   * generic_or1k Clock driver
>>>>>   *
>>>>>   * COPYRIGHT (c) 2014-2015 Hesham ALMatary <heshamelmat...@gmail.com>
>>>>> + * Copyright (c) 2014-2016 ÅAC Microtec AB <www.aacmicrotec.com>
>>>>> + *                         Jakob Viketoft 
>>>>> <jakob.viket...@aacmicrotec.com>
>>>>>   *
>>>>>   * The license and distribution terms for this file may be
>>>>>   * found in the file LICENSE in this distribution or at
>>>>> @@ -25,35 +27,30 @@
>>>>>  #include <rtems/timecounter.h>
>>>>>
>>>>>  /* The number of clock cycles before generating a tick timer interrupt. 
>>>>> */
>>>>> -#define TTMR_NUM_OF_CLOCK_TICKS_INTERRUPT     0x09ED9
>>>>> -#define OR1K_CLOCK_CYCLE_TIME_NANOSECONDS     10
>>>>> +#define OR1K_CLOCK_CYCLE_TIME_NANOSECONDS     (1000000000 / 
>>>>> OR1K_BSP_CLOCK_FREQ)
>>>>clockdrv.c:30:61: error: 'OR1K_BSP_CLOCK_FREQ' undeclared (first use
>>>>in this function)
>>>
>>> Sorry for the delay in responding, it took me a while to figure this one 
>>> out since I had to build a new toolchain and stuff to make sure I was using 
>>> same as you. I had rather quickly transfered the change from what we were 
>>> doing in our own BSP.
>>>
>> Thanks for doing this.
>>
>>> Basically, there is a copy-paste error between the 
>>> generic_or1k/include/bsp.h and generic_or1k/include/generic_or1k.h include 
>>> guards which both define the same thing. Change the one in bsp.h and 
>>> everything compiles as it should. This is somewhat outside this patch's 
>>> intentions, but should this patch address this as well?
>>>
>> Great catch. I already have a local fix, if you prefer not to submit a
>> patch for this bug separately, I am happy to submit it.
>>
>>> Jakob Viketoft
>>> Senior Engineer in RTL and embedded software
>>>
>>> ÅAC Microtec AB
>>> Dag Hammarskjölds väg 48
>>> SE-751 83 Uppsala, Sweden
>>>
>>> T: +46 702 80 95 97
>>> http://www.aacmicrotec.com
>>
>>
>>
>> --
>> Hesham
>
>
>
> --
> Hesham



-- 
Hesham
_______________________________________________
devel mailing list
devel@rtems.org
http://lists.rtems.org/mailman/listinfo/devel

Reply via email to