Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
10 years ago

_hw.tcl advice entries on Custom IPs

Thanks in advance.

I have three custom IPs and I'd like to write one device driver that includes all of these components.

In each of the _hw.tcl files I made a common GROUP name: CUSTOM_IPS (the set_module_assignment embeddedsw.dts.group from what I've read is necessary for the device tree?)

They all have the same embeddedsw.dts.compatible statement in their respective _hw.tcl files.

"set_module_assignment embeddedsw.dts.compatible " jpe,jpe-1.0"

I successfully got my new .dtb file and in the /proc/device-tree/sopc@/bridge@0xc0000000 directory when I do and "ls" command I see the directories:

CUSTOM_IPS@0x100000000

CUSTOM_IPS@0x100030010

CUSTOM_IPS@0x100040000

When I load my device driver it PROBES three times and fails on the second two probes with:

jpe: probe of ff200000.CUSTOM_IPS failed with error -5

MY QUESTION IS --- Is it possible to access three separate memory spaces of the three custom IPs with this new scheme in the same device driver or do I have to write three separate device drivers?

If the answer is yes, then what do I do to the _hw.tcl file(s) about the GROUP name.

1 Reply

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    O.K. AFTER THINKING --> it makes sense to write three device drivers because I may use these IP's again in different designs.

    So, that's what I'm going to do. I'd still be interested if someone has any valid comments on this subject.