one typo fix
PATCH 1/3 one typo fix
--- drivers/staging/crystalhd/bc_dts_defs.h | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/staging/crystalhd/bc_dts_defs.h +1 -1
@@ -84,7 +84,7 @@ enum BC_SW_OPTIONS { BC_OPT_LINK_OUT_ENCRYPT = BC_BIT(29), }; -struct BC_REG_CONFIG { +struct BC_REG_CONFIG {uint32_t DbgOptions; };
Signature · 1 line
1.7.1
PATCH 2/3 syntax typos fix
Mostly spaces to tabs fix.
NOTE: This patch has 80 character warnings, but all this driver has a lot of them and I am not sure if it's worth the effort to fix it.
--- drivers/staging/crystalhd/bc_dts_defs.h | 2 +- drivers/staging/crystalhd/bc_dts_glob_lnx.h | 6 +- drivers/staging/crystalhd/crystalhd_cmds.c | 4 +- drivers/staging/crystalhd/crystalhd_cmds.h | 2 +- drivers/staging/crystalhd/crystalhd_fw_if.h | 532 +++++++++++++------------- drivers/staging/crystalhd/crystalhd_misc.h | 6 +- 6 files changed, 276 insertions(+), 276 deletions(-)
drivers/staging/crystalhd/bc_dts_defs.h +1 -1
@@ -391,7 +391,7 @@ struct BC_PIC_INFO_BLOCK {* ProcOut Info * *------------------------------------------------------*/ /* Optional flags for ProcOut Interface.*/ -enum POUT_OPTIONAL_IN_FLAGS_ { +enum POUT_OPTIONAL_IN_FLAGS_ {/* Flags from App to Device */ BC_POUT_FLAGS_YV12 =0x01 ,/* Copy Data in YV12 format */ BC_POUT_FLAGS_STRIDE =0x02 ,/* Stride size is valid. */
drivers/staging/crystalhd/bc_dts_glob_lnx.h +3 -3
@@ -175,7 +175,7 @@ struct BC_DEC_YUV_BUFFS {uint32_t RefCnt; }; -enum DECOUT_COMPLETION_FLAGS { +enum DECOUT_COMPLETION_FLAGS {COMP_FLAG_NO_INFO =0x00 ,COMP_FLAG_FMT_CHANGE =0x01 ,COMP_FLAG_PIB_VALID =0x02 ,
@@ -184,7 +184,7 @@ enum DECOUT_COMPLETION_FLAGS{ COMP_FLAG_DATA_BOT = 0x10, }; -struct BC_DEC_OUT_BUFF { +struct BC_DEC_OUT_BUFF {struct BC_DEC_YUV_BUFFS OutPutBuffs;struct BC_PIC_INFO_BLOCK PibInfo;uint32_t Flags;
@@ -289,7 +289,7 @@ struct crystalhd_ioctl_data {struct crystalhd_ioctl_data *next;/* List/Fifo management */ }; -enum crystalhd_kmod_ver { +enum crystalhd_kmod_ver { crystalhd_kmod_major =0 , crystalhd_kmod_minor =9 , crystalhd_kmod_rev =27 ,
drivers/staging/crystalhd/crystalhd_cmds.c +2 -2
@@ -309,9 +309,9 @@ static enum BC_STATUS bc_cproc_download_fw(struct crystalhd_cmd *ctx, sts =crystalhd_download_fw (ctx->adp, (uint8_t *)idata->add_cdata, idata->add_cdata_sz); -if (sts !=BC_STS_SUCCESS ) { +if (sts !=BC_STS_SUCCESS )BCMLOG_ERR ("Firmware Download Failure!! - %d\n" , sts); - }else +else ctx->state |=BC_LINK_INIT ;return sts;
drivers/staging/crystalhd/crystalhd_cmds.h +1 -1
@@ -36,7 +36,7 @@#include "crystalhd_misc.h" #include "crystalhd_hw.h" -enum crystalhd_state { +enum crystalhd_state {BC_LINK_INVALID =0x00 ,BC_LINK_INIT =0x01 ,BC_LINK_CAP_EN =0x02 ,
drivers/staging/crystalhd/crystalhd_fw_if.h +266 -266
581 lines not on this page · raw message
drivers/staging/crystalhd/crystalhd_misc.h +3 -3
@@ -205,12 +205,12 @@ enum _chd_log_levels {#define BCMLOG_ENTER \ if (g_linklog_level & BCMLOG_ENTER_LEAVE) { \ - printk("Entered %s\n", __func__); \ + printk(KERN_DEBUG "Entered %s\n", __func__); \ }#define BCMLOG_LEAVE \ if (g_linklog_level & BCMLOG_ENTER_LEAVE) { \ - printk("Leaving %s\n", __func__); \ + printk(KERN_DEBUG "Leaving %s\n", __func__); \ } #define BCMLOG(trace, fmt, args...) \
@@ -221,7 +221,7 @@ if (g_linklog_level & trace) { \ #define BCMLOG_ERR(fmt, args...) \ do { \ if (g_linklog_level & BCMLOG_ERROR) { \ - printk("*ERR*:%s:%d: "fmt, __FILE__, __LINE__, ##args); \ + printk(KERN_ERR "*ERR*:%s:%d: "fmt, __FILE__, __LINE__, ##args); \ } \ } while (0);
Signature · 1 line
1.7.1
PATCH 3/3 typedef cleanup
In reply to Arvydas SidorenkoMost of those typedefs weren't used, so simply removing them worked without any compilation issues.
--- drivers/staging/crystalhd/bc_dts_types.h | 41 +----------------------------- 1 files changed, 1 insertions(+), 40 deletions(-)
drivers/staging/crystalhd/bc_dts_types.h +1 -40
@@ -29,29 +29,8 @@#include <stdint.h> #endif -#ifndef PVOID -typedef void *PVOID ; -#endif - -#ifndef BOOL -typedef int BOOL ; -#endif -#if defined(__KERNEL__) || defined(__LINUX_USER__) -#ifdef __LINUX_USER__/* Don't include these for KERNEL */ -typedef uint32_t ULONG ; -typedef int32_t LONG ; -typedef void *HANDLE ; -#ifndef VOID -typedef void VOID ; -#endif -typedef void *LPVOID ; -typedef uint32_t DWORD ; -typedef uint32_t UINT32 ; -typedef uint32_t *LPDWORD ; -typedef unsigned char *PUCHAR ; -#ifndef TRUE #define TRUE 1#endif
@@ -70,28 +49,10 @@ typedef unsigned char *PUCHAR;#else #ifndef uint64_t -typedef struct _uint64_t { +struct _uint64_t {uint32_t low_dw;uint32_t hi_dw; } uint64_t;#endif -#ifndef int32_t -typedef signed long int32_t ; -#endif - -#ifndef uint32_t -typedef unsigned long uint32_t ;#endif - -#ifndef uint16_t -typedef unsigned short uint16_t ; -#endif - -#ifndef uint8_t -typedef unsigned char uint8_t ; -#endif -#endif - -#endif -
Signature · 1 line
1.7.1
Re: [PATCH 3/3] typedef cleanup
Quoted 7 lines · Arvydas Sidorenko
#ifndef
uint64_tdrivers/staging/crystalhd/bc_dts_types.h +1
-1-typedef struct _uint64_t { +struct _uint64_t {uint32_t low_dw; uint32_t hi_dw; } uint64_t;#endif
This can't be right can it? You're changing a typedef into a variable definition as far as I can see.
HTH,
Chris
Signature · 2 lines
Chris Boot [email protected]
Re: [PATCH 3/3] typedef cleanup
Quoted 12 lines · Chris Boot
Quoted 7 lines · Arvydas Sidorenko
#ifndef
uint64_tdrivers/staging/crystalhd/bc_dts_types.h +1
-1-typedef struct _uint64_t { +struct _uint64_t {uint32_t low_dw; uint32_t hi_dw; } uint64_t;#endif
This can't be right can it? You're changing a typedef into a variable definition as far as I can see.
Yes. You are right. The "uint64_t" is a variable now so this patch is wrong.
(Or maybe you knew that and the question was rhetorical? It's hard to tell over email.)
regards,
dan carpenter
Re: [PATCH 3/3] typedef cleanup
Quoted 14 lines · Dan Carpenter
Quoted 12 lines · Chris Boot
Quoted 7 lines · Arvydas Sidorenko
#ifndef
uint64_tdrivers/staging/crystalhd/bc_dts_types.h +1
-1-typedef struct _uint64_t { +struct _uint64_t {uint32_t low_dw; uint32_t hi_dw; } uint64_t;#endif
This can't be right can it? You're changing a typedef into a variable definition as far as I can see.
Quoted 5 lines
Yes. You are right. The "
uint64_t" is a variable now so this patch is wrong.(Or maybe you knew that and the question was rhetorical? It's hard to tell over email.)
Dan,
Sorry, I had just come back well-watered from a nice meal last night! :-) Yes I realised that wasn't what you meant to do with your patch, sorry it came out the wrong way.
Without looking at the code I imagine you could remove the entire definition above, but that's just a guess.
HTH,
Chris
Signature · 2 lines
Chris Boot [email protected]
Quoted 10 lines · Arvydas Sidorenko
Signed-off-by Arvydas Sidorenko <[email protected]>--- drivers/staging/crystalhd/bc_dts_defs.h | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)drivers/staging/crystalhd/bc_dts_defs.h +0
-0
drivers/staging/crystalhd/bc_dts_defs.h enum BC_SW_OPTIONS { · line 87
Quoted 5 lines
drivers/staging/crystalhd/bc_dts_defs.h +1
-1@@ -84,7 +84,7 @@ enum BC_SW_OPTIONS { BC_OPT_LINK_OUT_ENCRYPT = BC_BIT(29), }; -struct BC_REG_CONFIG { +struct BC_REG_CONFIG {
That's not a "typo", it's a style fix, right?
Also, please give a good Subject: line for your emails. This one would be:
Subject: staging: crystalhd: bc_dts_defs.h: fix a coding style issue
Care to redo all 3 patches in this series in this way, properly describing what you are doing, so I can apply them?
thanks,
greg k-h