Permalink
Browse files

Several bug fixes and feature requests:

- Linux driver loads properly now
- Indirect property support to support workers with properties at non-contiguous addressed,
---- typical of "parameter memories", like pattern gen and capture workers
- Support protocols including (sort of inheriting) other protocolls
- Support operation enumerations for protocols rather than ports, in RCC header
- More flexibility and uniformity as to where "property" xml elements can appear
- Support using the HDL control plane "window" feature
- Eliminate padding at the end of generated rcc protocol message structures
- Report basic XML parsing errors where is wasn't happening before (in xi:include)
doc/OpenCPI_RCC_Reference.pdf - an updated version including clarifications and a few new features
-- protocol enumerations independent of ports
-- setError container function for creating error strings like sprintf
-- RCC_ADVANCE_DONE to ADVANCE and finish in one return
adapt/os/ocpios/linux/driver/ocpi_linux_driver: resync driver memmap parameter name
components/specs/rstream_with_sync_protocol.xml: exploit new protocol inheritance feature
core/container/hdl_container/impl/include/HdlAccess.h: enable full worker API to work with hidden/infrastructure workers
--- some cleanup of unused args
core/container/hdl_container/impl/include/HdlOCCP.h: add macro for window size
core/container/hdl_container/impl/src/HdlAccess.cxx: remove unused args
core/container/hdl_container/impl/src/HdlContainer.cxx: support OCCP windowed config space
--- properties must fit in a window
--- no super-fast MMIO for these yet
--- move all property access stuff down to WciControl class, allowing it to be
------ used on infrastructure workers etc.
core/container/interfaces/api/src/OcpiMetadataWorker.cxx: parse method for property does not do offset calc
-- now deferred to propertly support indirect properties specified in the impl xml
-- thus offsets are only calculated after all the impl info is processed.
core/local/util/ezxml/include/OcpiUtilEzxml.h: add xml utilities to simply loop through children
core/local/util/ezxml/src/OcpiUtilEzxml.cxx: ditto
core/local/util/property/include/OcpiUtilProperty.h: add support for indirect property addressing
-- and reorganizate spec vs impl parsing to reduce redundancy
core/local/util/property/src/OcpiUtilProperty.cxx: ditto
core/local/util/property/include/OcpiUtilProtocol.h: support protocols including protocols finally
core/local/util/property/src/OcpiUtilProtocol.cxx: ditto
tools/cdk/cdkutils/src/cdkutils.cxx: properly report xml parsing errors in some cases
tools/cdk/include/xxx-worker.mk b/tools/cdk/include/xxx-worker.mk: debug prints
tools/cdk/ocpigen/ocpigen/src/wip_HDL.cxx: support indirect properties, remove bogus "library util;" in vhdl
tools/cdk/ocpigen/ocpigen/src/wip_RCC.cxx: generate protocol operation enumerations independent of ports
--- also force packing of message structures (Troy found the bug)
tools/cdk/ocpigen/ocpigen/src/wip_parse.cxx: more comprehensive property parsing structure
--- properties can be found anywhere - in control interface or not, top level or not,
--- using xi:include of Properties in files, or Properties anywhere
--- less code, and it works more consistently
--- xml files can be simpler
--- better error messages correctly reporting file names of parse errors included files
--- error check certain elements that should only occur once
components/bias_ver.hdl/bias_ver.xml: fixed bad xml that is now flaged due to better error checking
components/delay.hdl/delay.xml: ditto
  • Loading branch information...
1 parent 8c9c5d7 commit 9dcc615d1e6cf55b13f0a3a724558de0c3e4dd52 @jekulp jekulp committed Oct 14, 2012
@@ -1,7 +1,7 @@
#!/bin/sh
-# This script loads and unloads the linix driver
-# it is intended to be called from other script that checks args etc.
+# This script loads and unloads the linux driver
+# it is intended to be called from another script that checks args etc.
# Retrieve the reserved DMA memory value from the kernel command line
# Note there might be multiple reservations, and we currently only support one (the first).
@@ -85,7 +85,8 @@ if [ $1 == status ] ; then
fi
sudo cp $RULESPATH /etc/udev/rules.d
sudo /sbin/udevcontrol reload_rules
-sudo /sbin/insmod $MODPATH $MEMMAP
+sudo /sbin/insmod $MODPATH opencpi_$MEMMAP
+#sudo /sbin/modprobe -v
if [ $? == 0 ] ; then
# check /dev?
echo Driver loaded successfully.
@@ -2,6 +2,6 @@
<xi:include href="bias_spec.xml"/>
<StreamInterface Name="in" ImpreciseBurst="true" PreciseBurst="true" DataWidth="32" RegRequest="true" NumberOfOpcodes="256"/>
<StreamInterface Name="out" ImpreciseBurst="true" PreciseBurst="true" DataWidth="32" RegRequest="true" NumberOfOpcodes="256"/>
-</ComponentImplementation>
+</HdlImplementation>
@@ -34,6 +34,6 @@
<StreamInterface Name="in" ImpreciseBurst="true" PreciseBurst="true" DataWidth="32"/>
<StreamInterface Name="out" ImpreciseBurst="true" PreciseBurst="true" DataWidth="32"/>
<MemoryInterface DataWidth="128" ByteWidth="8" MemoryWords="4g" MaxBurstLength="4k-1" PreciseBurst="true" WriteDataFlowControl="true"/>
-</ComponentImplementation>
+</HdlImplementation>
@@ -1,11 +1,12 @@
<!-- A general real data protocol -->
<Protocol name="r16stream_data" >
- <!-- A general real data protocol -->
- <Operation Name="data" >
- <!-- Variable size frames with 16 bit real data values. Format:Qs0.15 -->
- <Argument name="real" type="Short" SequenceLength="4096" />
- </Operation>
+ <xi:include href='rstream_data_protocol.xml'/>
+ <!-- <\!-\- A general real data protocol -\-> -->
+ <!-- <Operation Name="data" > -->
+ <!-- <\!-\- Variable size frames with 16 bit real data values. Format:Qs0.15 -\-> -->
+ <!-- <Argument name="real" type="Short" SequenceLength="4096" /> -->
+ <!-- </Operation> -->
<!-- A general I/O sync protocol for a signal processing stream -->
<!-- zero size frames indicating a phase discontinuity - i.e. samples not continuous-->
@@ -29,22 +29,22 @@ namespace OCPI {
virtual void setBytes(RegisterOffset, const uint8_t *, unsigned, uint32_t *status = NULL) = 0;
};
class Access {
- friend class Worker;
+ friend class WciControl;
volatile uint8_t *m_registers; // the memory mapped virtual address of the registers
uint64_t m_base; // the base of the "registers" in their physical address space
Accessor *m_accessor; // when no virtual pointer access, the object that does the access
- volatile uint8_t *m_buffers; // sort of a hack for the data plane until enet dp is available
+ // volatile uint8_t *m_buffers; // sort of a hack for the data plane until enet dp is available
public:
Access(Access &other);
Access(volatile uint8_t *registers = NULL, Accessor *accessor = NULL,
- RegisterOffset base = 0, volatile uint8_t *buffers = NULL);
+ RegisterOffset base = 0); //, volatile uint8_t *buffers = NULL);
~Access();
inline volatile uint8_t *registers() const { return m_registers; }
inline bool usable() const { return m_registers || m_accessor; }
void
setAccess(volatile uint8_t *registers, Accessor *accessor = NULL,
- RegisterOffset base = 0, volatile uint8_t *buffers = NULL);
+ RegisterOffset base = 0); //, volatile uint8_t *buffers = NULL);
void
closeAccess();
@@ -108,7 +108,8 @@ namespace OCPI {
#define OCCP_ADMIN_SIZE OCCP_WORKER_CONTROL_SIZE
#define OCCP_ADMIN_CONFIG_OFFSET 4096
#define OCCP_ADMIN_CONFIG_SIZE 4096
-#define OCCP_WORKER_CONFIG_SIZE 0x100000
+#define OCCP_WORKER_CONFIG_WINDOW_BITS 20
+#define OCCP_WORKER_CONFIG_SIZE (1 << OCCP_WORKER_CONFIG_WINDOW_BITS)
#define OCCP_WORKER_CONTROL_BASE(i) ((i) * OCCP_BYTES_PER_WORKER)
#define OCCP_WORKER_PROPERTY_BASE(i) ((i) * OCCP_BYTES_PER_WORKER)
// Magic values from config space: these values are 32 bit values with chars big endian
@@ -3,14 +3,15 @@
namespace OCPI {
namespace HDL {
Access::
- Access(volatile uint8_t *registers, Accessor *accessor, RegisterOffset base,
- volatile uint8_t *buffers) : m_accessor(NULL) {
- setAccess(registers, accessor, base, buffers);
+ Access(volatile uint8_t *registers, Accessor *accessor, RegisterOffset base)
+ //, volatile uint8_t *buffers)
+ : m_accessor(NULL) {
+ setAccess(registers, accessor, base); //, buffers);
}
// Take the content and ownership away from the other access structure
Access::
Access(Access &other) : m_accessor(NULL) {
- setAccess(other.m_registers, other.m_accessor, other.m_base);
+ setAccess(other.m_registers, other.m_accessor); //, other.m_base);
}
Access::
@@ -20,12 +21,12 @@ namespace OCPI {
void Access::
setAccess(volatile uint8_t *registers, Accessor *accessor,
- RegisterOffset base, volatile uint8_t *buffers) {
+ RegisterOffset base) { //, volatile uint8_t *buffers) {
delete m_accessor;
m_registers = registers;
m_accessor = accessor;
m_base = base;
- m_buffers = buffers;
+ // m_buffers = buffers;
}
void Access::
Oops, something went wrong.

0 comments on commit 9dcc615

Please sign in to comment.