This is the mail archive of the ecos-patches@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Clean warning on quicc2_diag.c


Compiler is issuing a warning 'larged integer implicitly truncated to 
unsigned byte type' at ligne 407 of quicc2_diag.c (1.4).

In fact 0xFFFF is assigned to a smc_smce which is a CYG_BYTE type ... that 
means a byte. 
(infra/current/include/cyg_type.h:typedef cyg_uint8   CYG_BYTE;)

Here's the patch :
diff -a -w -u -r 1.4 quicc2_diag.c
--- 1.4/quicc2_diag.c   Thu Mar 11 10:30:47 2004
+++ quicc2_diag.c       Thu Mar 11 11:08:19 2004
@@ -404,7 +404,7 @@
     regs->smc_smcmr = 0x4823;

     // Clear events
-    regs->smc_smce = 0xFFFF;
+    regs->smc_smce = 0xFF;
     regs->smc_smcm = SMCE_Rx;

     // Init channel


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]