Re: [PATCH 2/2] bsp/xilinx-zynq: Add device configuration driver

2017-04-20 Thread Chris Johns
On 21/04/2017 07:52, Patrick Gauvin wrote: Chris, + +static drvdata data; +/* TODO: Abstract DMA buffer retrieval better */ Agreed. +static uint8_t *dma_buf = NULL; + +/* Check if bit is set in reg (and not masked by mask), and if

Re: [PATCH 0/2] Zynq7000 series device configuration driver

2017-04-20 Thread Chris Johns
On 21/04/2017 07:55, Patrick Gauvin wrote: Gedare, if the test programs are specific to the Zynq BSP, then we don't currently have a very good mechanism for maintaining them. Probably submitting them as "example programs" in the git.rtems.org/examples-v2.git

Re: [PATCH 1/2] bsp/xilinx-zynq: Add SLCR driver

2017-04-20 Thread Patrick Gauvin
Thank you, that does simplify things quite a bit. -Patrick On Thu, Apr 20, 2017 at 5:50 PM, Chris Johns wrote: > On 21/04/2017 07:22, Patrick Gauvin wrote: > >> >> I so not like the reset value being written to like this. I know you >> need to set the lower 4 bits to 1 when loading the

Re: [PATCH 0/2] Zynq7000 series device configuration driver

2017-04-20 Thread Patrick Gauvin
Gedare, > if the test programs are specific to the Zynq BSP, then we don't > currently have a very good mechanism for maintaining them. Probably > submitting them as "example programs" in the > git.rtems.org/examples-v2.git is the best place to look at integrating > application/bsp-level tests. T

Re: [PATCH 2/2] bsp/xilinx-zynq: Add device configuration driver

2017-04-20 Thread Patrick Gauvin
Chris, >> + >> +static drvdata data; >> +/* TODO: Abstract DMA buffer retrieval better */ >> > > Agreed. > > > +static uint8_t *dma_buf = NULL; >> + >> +/* Check if bit is set in reg (and not masked by mask), and if it is, >> write >> + * that bit to reg, returning true. Otherwise return false. >

Re: [PATCH 1/2] bsp/xilinx-zynq: Add SLCR driver

2017-04-20 Thread Chris Johns
On 21/04/2017 07:22, Patrick Gauvin wrote: I so not like the reset value being written to like this. I know you need to set the lower 4 bits to 1 when loading the fabric via PCAP but there are 4 independent resets and I have applications that have individual control once loaded.

Re: [PATCH 1/2] bsp/xilinx-zynq: Add SLCR driver

2017-04-20 Thread Patrick Gauvin
Chris, >> + >> +#define ZYNQ_SLCR_BASE_ADDR ( 0xF800 ) >> +/* NOTE: QEMU gives a value of 0 for the pss_idcode. */ >> +#define ZYNQ_SLCR_PSS_IDCODE_OFF ( 0x530 ) >> +#define ZYNQ_SLCR_PSS_IDCODE_DEVICE_GET( reg ) BSP_FLD32GET( reg, 12, >> 16 ) >> +#define ZYNQ_SLCR_LVL_SHFTR_EN_OFF ( 0x900 )

Re: [PATCH 0/2] Zynq7000 series device configuration driver

2017-04-20 Thread Gedare Bloom
On Wed, Apr 19, 2017 at 11:06 PM, Patrick Gauvin wrote: > Hello, > > I'm submitting this device configuration driver to be reviewed and > hopefully to be accepted into the RTEMS source tree. In its current state, it > is able to send PCAP command sequences, successfully program the FPGA, and > als