<div dir="ltr"><br><br><div class="gmail_quote">On Mon, Jan 3, 2011 at 5:09 PM, Kfir Lavi <span dir="ltr">&lt;<a href="mailto:lavi.kfir@gmail.com">lavi.kfir@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

<div dir="ltr"><div><div></div><div class="h5"><br><br><div class="gmail_quote">On Mon, Jan 3, 2011 at 3:00 PM, Philip Downer <span dir="ltr">&lt;<a href="mailto:phil@pjd.me.uk" target="_blank">phil@pjd.me.uk</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div><div></div><div>On 03/01/11 12:47, Kfir Lavi wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
I have a FPGA that is constantly changing (its on development phase).<br>
I want to let userspace app to update those registers, but don&#39;t want to<br>
create an API yet.<br>
What is the best way to open a range of registers to userspace, so no<br>
driver update is required?<br>
</blockquote>
<br></div></div>
When I had to do this recently I used sysfs, I have no idea if it&#39;s the best way but it certainly was very effective. Remember in sysfs that each file should only have one value.<br>
<br>
Once it&#39;s setup though you can just write to the sysfs files, I started by writing simple perl scripts to test things before starting to write more complex apps.<br>
<br>
HTH<br>
<br>
Phil<br>
</blockquote></div></div></div>So what do expose in sysfs? for each register - a file of it&#39;s own? or you get a bulk of data to one file?<br><br>Thanks,<br>Kfir<br></div>
</blockquote></div><br>I thought about using 3 files in sysfs. <br>1. address of the register<br>2. data to write to the register<br>3. trigger that do the write<br><br>Please share your comments.<br>Regards,<br>Kfir<br>

</div>