Windows 7 1394 isochronous talk with variable sized packets

Hello,

I have been reworking our driver to use variable sized talk packets. With Windows 7, when I attempt to attach the isochronous buffer (REQUEST_ISOCH_ATTACH_BUFFERS), the request fails with error code STATUS_INVALID_PARAMETER.

I can see from other discussions on this list that the new 1394 driver stack for Windows 7 performs more error checking on submitted IRBs than previous versions of Windows. I went through all of the parameters in the descriptor, paying particular attention to nMaxBytesPerFrame, but everything looked okay.

The driver works fine if I use fixed size talk packets, but we get a significant performance increase with variable sized packets.

So-can anyone tell me how to enable debug tracing for1394ohci.sys with Windows 7 RTM? At the moment, I don’t know which parameter it’s objecting to.

Thanks very much,

Matt

Hi Matt,

Please do below to get a 1394 debug log:

  • Copy text at end of post to enableautotrace.cmd file
  • Disconnect all devices connected over 1394 to system
  • run "enableautotrace.cmd’ with elevated cred from a command prompt
  • reboot the machine, repro the issue, reboot again
  • copy 1394ohci.etl.xxx from %windir%\tracing to a ZIP file and send to xxxxx@microsoft.com
  • Also copy %windir%\inf\setupapi.dev.log to ZIP file

Thanks,

-Don [MS]

Copy below text into an enableautotrace.cmd file and run the steps above:

@setlocal
echo off
rem
rem Default build to use will be 1394ohci
rem
echo.
set binaryname=1394ohci
set binaryguid=3979F0A6-8A10-4cfd-BF20-9E45279D6C19

if “%1” NEQ “” (
set binaryguid=%1
if “%2”==“” (
echo.
echo ERROR: No binary guid was specified for ‘%1’
goto :syntax
)
set binaryguid=%2
)

@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%{%binaryguid%}” /v EnableFlags /t REG_DWORD /d 0xffffffff /f
@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%{%binaryguid%}” /v EnableLevel /t REG_DWORD /d 0xffffffff /f
@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%{%binaryguid%}” /v Enabled /t REG_DWORD /d 0x1 /f
@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%{%binaryguid%}” /v Status /t REG_DWORD /d 0 /f

@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%” /v GUID /t REG_SZ /d {%binaryguid%} /f
@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%” /v FileName /t REG_SZ /d %SystemRoot%\Tracing%binaryname%.etl /f
@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%” /v FileMax /t REG_DWORD /d 1000 /f
@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%” /v MaxFileSize /t REG_DWORD /d 1000 /f
@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%” /v LogFileMode /t REG_DWORD /d 0x1202 /f
@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%” /v Start /t REG_DWORD /d 1 /f
@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%” /v Status /t REG_DWORD /d 0 /f
@REG ADD “HKLM\System\CurrentControlSet\Control\WMI\Autologger%binaryname%” /v FlushTimer /t REG_DWORD /d 1 /f

goto :done

:syntax
echo.
echo ***************** SYNTAX ****************
echo enableautotrace.cmd [name] [guid]
echo name = Name for the component (ex: 1394ohci)
echo guid = Guid for the component (ex: 3979F0A6-8A10-4cfd-BF20-9E45279D6C19)
echo.
echo.

:done

Apparently with Windows 7, if you specify RESOURCE_VARIABLE_ISOCH_PAYLOAD then nNumberOfDescriptors for both attach and detach operations must be exactly 2. I changed my driver accordingly and it works fine now.

Many thanks to Don Miller for his help with tracking this down.