From 7377e9336d2754e9e820212ee80c6f16b8831951 Mon Sep 17 00:00:00 2001 From: Allen Martin Date: Mon, 19 Nov 2012 15:08:54 -0800 Subject: Add descripton of nv3p packets Add some documentation of nv3p packet formats as comments Signed-off-by: Allen Martin Change-Id: I5685612b75bb2150ca5307497c5b83d18aa8da6b Reviewed-on: http://git-master/r/164849 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Stephen Warren --- src/nv3p.c | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 70 insertions(+) diff --git a/src/nv3p.c b/src/nv3p.c index 19c5976..b3f6045 100644 --- a/src/nv3p.c +++ b/src/nv3p.c @@ -36,6 +36,76 @@ #include "usb.h" #include "debug.h" +/* nv3p command packet format */ +/*|------------32 bits--------------|*/ +/*************************************/ +/* NV3P_VERSION */ +/*-----------------------------------*/ +/* NV3P_PACKET_TYPE_CMD */ +/*-----------------------------------*/ +/* sequence no */ +/*-----------------------------------*/ +/* length of command arguments */ +/*-----------------------------------*/ +/* command, one of: */ +/* NV3P_CMD_GET_PLATFORM_INFO */ +/* NV3P_CMD_DL_BCT */ +/* NV3P_CMD_DL_BL */ +/* NV3P_CMD_STATUS */ +/*-----------------------------------*/ +/* command arguments */ +/* . */ +/* . */ +/* . */ +/*-----------------------------------*/ +/* checksum */ +/*-----------------------------------*/ + +/* nv3p ack packet format */ +/*|------------32 bits--------------|*/ +/*************************************/ +/* NV3P_VERSION */ +/*-----------------------------------*/ +/* NV3P_PACKET_TYPE_ACK */ +/*-----------------------------------*/ +/* sequence no */ +/*-----------------------------------*/ +/* checksum */ +/*-----------------------------------*/ + +/* nv3p nack packet format */ +/*|------------32 bits--------------|*/ +/*************************************/ +/* NV3P_VERSION */ +/*-----------------------------------*/ +/* NV3P_PACKET_TYPE_NACK */ +/*-----------------------------------*/ +/* sequence no */ +/*-----------------------------------*/ +/* nack code */ +/*-----------------------------------*/ +/* checksum */ +/*-----------------------------------*/ + +/* nv3p data packet format */ +/*|------------32 bits--------------|*/ +/*************************************/ +/* NV3P_VERSION */ +/*-----------------------------------*/ +/* NV3P_PACKET_TYPE_DATA */ +/*-----------------------------------*/ +/* sequence no */ +/*-----------------------------------*/ +/* length of data */ +/*-----------------------------------*/ +/* data */ +/* . */ +/* . */ +/* . */ +/*-----------------------------------*/ +/* checksum */ +/*-----------------------------------*/ + typedef struct nv3p_state { usb_device_t *usb; uint32_t sequence; -- cgit v1.2.1