Re: [PATCH v3] powerpc/srio: Fix the compile errors when building with 64bit

From: Kumar Gala
Date: Fri Mar 16 2012 - 11:13:33 EST



On Mar 9, 2012, at 2:10 AM, Liu Gang wrote:

> For the file "arch/powerpc/sysdev/fsl_rmu.c", there will be some compile
> errors while using the corenet64_smp_defconfig:
>
> .../fsl_rmu.c:315: error: cast from pointer to integer of different size
> .../fsl_rmu.c:320: error: cast to pointer from integer of different size
> .../fsl_rmu.c:320: error: cast to pointer from integer of different size
> .../fsl_rmu.c:320: error: cast to pointer from integer of different size
> .../fsl_rmu.c:330: error: cast to pointer from integer of different size
> .../fsl_rmu.c:332: error: cast to pointer from integer of different size
> .../fsl_rmu.c:339: error: cast to pointer from integer of different size
> .../fsl_rmu.c:340: error: cast to pointer from integer of different size
> .../fsl_rmu.c:341: error: cast to pointer from integer of different size
> .../fsl_rmu.c:348: error: cast to pointer from integer of different size
> .../fsl_rmu.c:348: error: cast to pointer from integer of different size
> .../fsl_rmu.c:348: error: cast to pointer from integer of different size
> .../fsl_rmu.c:659: error: cast from pointer to integer of different size
> .../fsl_rmu.c:659: error: format '%8.8x' expects type 'unsigned int',
> but argument 5 has type 'size_t'
> .../fsl_rmu.c:985: error: cast from pointer to integer of different size
> .../fsl_rmu.c:997: error: cast to pointer from integer of different size
>
> Rewrote the corresponding code with the support of 64bit building.
>
> Signed-off-by: Liu Gang <Gang.Liu@xxxxxxxxxxxxx>
> Signed-off-by: Shaohui Xie <Shaohui.Xie@xxxxxxxxxxxxx>
> Reported-by: Paul Gortmaker <paul.gortmaker@xxxxxxxxxxxxx>
> ---
> Changes in v2:
> - Add the struct "rio_dbell_msg" to instead of some DBELL_* macros.
> - Change the "virt_buf" to be "void *" type.
> - Change "Signed-off-by" to "Reported-by" for Paul.
>
> Changes in v3:
> - Change the "%8.8lx" to be "%p" and remove the cast of the "buffer"
>
> arch/powerpc/sysdev/fsl_rmu.c | 42 +++++++++++++++++++++-------------------
> 1 files changed, 22 insertions(+), 20 deletions(-)

applied

- k--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/