Hi Martyn,

On Mon, Jan 13, 2014 at 6:49 AM, Michael Kenney <mfken...@gmail.com> wrote:
> Hi Martyn,
>
> On Mon, Jan 13, 2014 at 4:00 AM, Martyn Welch <martyn.we...@ge.com> wrote:
> [snip]
>>
>> Hi Mike,
>>
>> I'm a little bemused by this one - I haven't managed to replicate it yet. I
>> have a feeling that the VME driver in version 3.2 won't use 16-bit transfers
>> at the beginning of blocks that aren't naturally aligned (it does D8, D8, D8,
>> D32... rather than D8, D16, D32... but I'm fairly sure it was doing the bulk
>> of a large transfer correctly).
>>
>> I've got some test code here you could try (VME address may need modifying to
>> something more appropriate to you - I have an old PPC board acting as a slave
>> at 0x8BB00000 in my system). I'm running this on a 3.12 kernel, but this
>> should work (could you try a newer version of the kernel?):
>>
> [code removed]
>>
>> I've plugged in an analyser, everything looks good here, 32-bit reads and
>> writes. I've confirmed that I see 16-bit cycles when I set dwidth to 2.
>
> Thanks, I will trying running the test code later this week. As for
> upgrading the kernel, I will certainly look into it.
>

Since my existing code basically does the same thing as your test
program, I decided to go ahead and update the kernel to 3.12 and rerun
my own code.

Unfortunately, the results are the same. I'm running this from home so
I'll have to confirm with the logic-analyzer tomorrow but the bridge
driver error messages suggest the same D8 writes (which for some
reason our A/D board does not like). Here's a dmesg excerpt:

[ 5631.810902] vme_tsi148 0000:02:02.0: VME Bus Error at address:
0x508000, attributes: 8008b900
[ 5631.810972] vme_tsi148 0000:02:02.0: VME Bus Exception Overflow Occurred
[ 5631.810977] vme_tsi148 0000:02:02.0: VME Bus Error at address:
0x508001, attributes: c0087900
[ 5631.810991] vme_tsi148 0000:02:02.0: VME Bus Error at address:
0x508003, attributes: 80087900
[ 5631.811061] vme_tsi148 0000:02:02.0: VME Bus Exception Overflow Occurred

The register that I am trying to write occupies 4 bytes starting at
0x508000. I have verified that the value I am trying to write to the
register is 4-byte aligned. I'm essentially doing the following:

uint32_t value;
pwrite(window_fd, &value, sizeof(value), 0x508000);

Window is configured for A24 and D32.

Does the "attributes" value from the tsi148 provide any further clues?

--Mike
_______________________________________________
devel mailing list
de...@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

Reply via email to