element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Avnet Boards Forums
  • Products
  • Dev Tools
  • Avnet Boards Community
  • Avnet Boards Forums
  • More
  • Cancel
Avnet Boards Forums
Ultrazed Hardware Design Cache Library on the UltraZed
  • Forum
  • Documents
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Avnet Boards Forums to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Suggested Answer
  • Replies 6 replies
  • Answers 5 answers
  • Subscribers 325 subscribers
  • Views 1165 views
  • Users 0 members are here
  • debian buster
  • cacheflush.h
  • arm cortex a53
  • embedded linux
  • xilinx zynq ultrascale+
  • kernel modules
  • gnu linux
  • cacheflush
  • linux device drivers
  • petalinux
  • xilinx
  • linux kernel
  • linux debian
  • ultrazed-eg
  • linux modules
  • petalinux tools
  • cache
  • arm-64-bit
  • xilinx zynq® ultrascale+ mpsoc
  • Embedded Systems
  • xilinx-linux
  • cache.h
  • ultrazed-eg-iocc
  • kernel
  • outercache.h
  • debian10
  • module
Related

Cache Library on the UltraZed

bhoevding
bhoevding over 6 years ago

Hello,

 

I am currently trying to build a kernel module, which contains functions like cache-flushing.

 

Some background Information as to how my System is generated:

I am using the Xilinx-V2019.1-Toolchain (Vivado & SDK, PetaLinux Tools) to generate all the required Embedded Linux components like bootloader, kernel image and device tree. Furthermore I have cloned the Xilinx-Linux-Repository, switched to the V2019.1 branch and configured PetaLinux Tools to use the specific Xilinx-Linux-Repo to generate the components using the repository. My platform is the Avnet-UltraZed-EG-IOCC Board and I am using a Debian-10 root filesystem for development. The Module I am trying to compile has worked on other Zynq-7000 Dev. Boards which have a different CPU-Architecture (32-Bit).

 

The issue:

The module won't compile, because I am trying to use kernel functions form a header which doesn't exist (outercache.h).

 

Regarding the outercache.h header, someone pointed out to me that this library can only be used on ARM-32-Bit-CPUs. As of right now I have worked through the arch/arm/include/asm/*.h and arch/arm64/include/asm/*.h within the Xilinx-Linux-Repository and found some other headers. But the problem persists, that the relevant headers (for example from the arm64-dir: cache.h, cacheflush.h) are not build. I have tried building the headers using PetaLinux Tools, as well as Cross Compiling using make xilinx_zynqmp_defconfig, make deb-pkg, make headers_install. Using the find command I have not figured out how to generate these cache headers, which could be the solution to my problem.

Another tip which I received on the Xilinx Forum was to include the following line CONFIG_OUTER_CACHE=y in the  xilinx_zynqmp_defconfig, which seemed promising but also didn't help me generating the required headers.

The only cache-relevant header being built on my system is located under /usr/include/linux/bcache.h, but doesn't contain any helpful functions for my module.

 

So as of right now I am really desperate to find out, how the cache can be flushed on 64-Bit Architectures from the Xilinx Zynq UltraScale+ Series. Hopefully someone can help me out with this issue, it might also help future developers.

I am depending on this to work for my application which is why I am trying to get help from both Forums here as well as the Xilinx Forum (see https://forums.xilinx.com/t5/Embedded-Linux/Cacheflush-not-working/m-p/1009218#M35867)

 

I would appreciate all the help I can get and please reply should you need more details, screenshots or other information,

 

best regards,

Bjørn

 

Message was edited by: Bjørn Hövding

  • Sign in to reply
  • Cancel

Top Replies

  • bhoevding
    bhoevding over 6 years ago in reply to clem57 +1
    Hello @BB-Sphere, could you explain your question, I am not sure what you mean. Goal: I am trying to flush the Cache using Kernel functions. Problem: The Kernel library which is built through PetaLinux…
  • clem57
    clem57 over 6 years ago +1 suggested
    I think this blog points to your issue https://forums.xilinx.com/t5/Embedded-Development-Tools/Trouble-creating-Linux-Application-in-SDK-2016-2-or-2016-4/td-p/… Have you seen https://www.instructables…
  • bhoevding
    bhoevding over 6 years ago in reply to clem57 +1 suggested
    Hello clem57 and Using Xilinx Tools Forum , Avnet Board Forums , UltraZed , Avnet , Xilinx , first of all thank you for looking into this matter and helping me out with your expertise. I have looked into…
Parents
  • clem57
    0 clem57 over 6 years ago

    I think this blog points to your issue https://forums.xilinx.com/t5/Embedded-Development-Tools/Trouble-creating-Linux-Application-in-SDK-2016-2-or-2016-4/td-p/…

    Have you seen https://www.instructables.com/id/Getting-Started-With-PetaLinux/

     

    Ha and this https://assil.me/2017/10/24/building-a-petalinux-project.html  But it seems to leave out the details.

     

    Clem

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
  • bhoevding
    0 bhoevding over 6 years ago in reply to clem57

    Hello clem57 and Using Xilinx Tools Forum, Avnet Board Forums, UltraZed, Avnet, Xilinx,

     

    first of all thank you for looking into this matter and helping me out with your expertise. I have looked into these links and will work them through more thoroughly.

    From what I read and tried, my problem with the Linux User Space Library / Kernel Headers still persist.

     

    I have also tried building the module using the PetaLinux Tools Workflow:

     

    petalinux-create -t modules --name <user-module-name> --enable

     

    but this is a dead end due to multiple reasons.

     

    Using the Approach from https://forums.xilinx.com/t5/Embedded-Development-Tools/Trouble-creating-Linux-Application-in-SDK-2016-2-or-2016-4/td-p/… doesn't seem very promising but I will definitely try it. There is some resemblance to their issue and the issue I am working with.

     

    The other Workflows describing how to generate the linux components unfortunately didn't give any new insights, although they are a genuine and very well documented resource to get started with the PetaLinux Toolchain.

     

    Regarding my issue I am almost certain that the issue is within the configuration https://github.com/Xilinx/linux-xlnx of arch/arm64/configs/xilinx_zynqmp_defconfig or some switch / configuration with in PetaLinux preventing the Cache Headers to be built. But this is only an assumption based on my research, the solution could lie somewhere completely different.

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
Reply
  • bhoevding
    0 bhoevding over 6 years ago in reply to clem57

    Hello clem57 and Using Xilinx Tools Forum, Avnet Board Forums, UltraZed, Avnet, Xilinx,

     

    first of all thank you for looking into this matter and helping me out with your expertise. I have looked into these links and will work them through more thoroughly.

    From what I read and tried, my problem with the Linux User Space Library / Kernel Headers still persist.

     

    I have also tried building the module using the PetaLinux Tools Workflow:

     

    petalinux-create -t modules --name <user-module-name> --enable

     

    but this is a dead end due to multiple reasons.

     

    Using the Approach from https://forums.xilinx.com/t5/Embedded-Development-Tools/Trouble-creating-Linux-Application-in-SDK-2016-2-or-2016-4/td-p/… doesn't seem very promising but I will definitely try it. There is some resemblance to their issue and the issue I am working with.

     

    The other Workflows describing how to generate the linux components unfortunately didn't give any new insights, although they are a genuine and very well documented resource to get started with the PetaLinux Toolchain.

     

    Regarding my issue I am almost certain that the issue is within the configuration https://github.com/Xilinx/linux-xlnx of arch/arm64/configs/xilinx_zynqmp_defconfig or some switch / configuration with in PetaLinux preventing the Cache Headers to be built. But this is only an assumption based on my research, the solution could lie somewhere completely different.

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
Children
No Data
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube