The BugID and synopsis are ok. The description and the fix does not match it though...
Copy paste error? ~Kini On Thu, 14 Feb 2008 00:52 -0000, krishna kumar wrote: }Sir, }me,Krishnakumar and rejeeshnath worked on the following bug and it seems to }be fixed. }The output is as expected and fine. We would like u to check the same } }*SCA Number:OS 0191 }user id is : krishna. } }Rejeesh's SCA Number:OS 0186 }user id:rej* }*BUG ID : 6425061* } }*SYNOPSIS:* thread.h t_nomigrate, naked char type is not portable, should }be signed } }CATEGORY & SUBCATEGORY: kernel:header } }DESCRIPTION: }A simple typographical error in usr/src/uts/common/sys/ccompile.h }breaks kernel builds using the GNU C compiler (gcc). }The attribute 'cmn_err' is specified, where it was obviously }intended to be 'printf'. } }Suggested fix: } }@@ -69,9 +69,9 @@ }#define __sun_attr___KVPRINTFLIKE__ __sun_attr___VPRINTFLIKE__ }#else }#define __sun_attr___KPRINTFLIKE__(__n) \ }- __attribute__((__format__(cmn_err, __n, (__n)+1))) }+ __attribute__((__format__(printf, __n, (__n)+1))) }#define __sun_attr___KVPRINTFLIKE__(__n) \ }- __attribute__((__format__(cmn_err, __n, 0))) }+ __attribute__((__format__(printf, __n, 0))) }#endif }In usr/src/uts/common/sys/thread.h, the declaration of t_nomigrate }is naked 'char'. Since it is used as a signed char, it should be }declared explicitly as 'signed char'. } }On PowerPC, naked char is unsigned. } }Suggested fix: }@@ -137,7 +137,7 @@ } uint8_t t_lockstat; /* set while thread is in lockstat code */ } uint8_t t_pil; /* interrupt thread PIL */ } disp_lock_t t_pi_lock; /* lock protecting t_prioinv list */ }- char t_nomigrate; /* do not migrate if set */ }+ signed char t_nomigrate; /* do not migrate if set */ } struct cpu *t_cpu; /* CPU that thread last ran on */ } struct cpu *t_weakbound_cpu; /* cpu weakly bound to */ } struct lgrp_ld *t_lpl; /* load average for home lgroup */ }*DIFF OUTPUT:* }***************************************************************************************** }--- thread.h.orig Thu Feb 14 00:33:06 2008 }+++ thread.h Thu Feb 14 00:43:52 2008 }@@ -139,7 +139,7 @@ } uint8_t t_lockstat; /* set while thread is in lockstat code */ } uint8_t t_pil; /* interrupt thread PIL */ } disp_lock_t t_pi_lock; /* lock protecting t_prioinv list */ }- char t_nomigrate; /* do not migrate if set */ }+ signed char t_nomigrate; /* do not migrate if set */ } struct cpu *t_cpu; /* CPU that thread last ran on */ } struct cpu *t_weakbound_cpu; /* cpu weakly bound to */ } struct lgrp_ld *t_lpl; /* load average for home lgroup */ }****************************************************************************************** } }Looking forward to hear from you } }Thanking you sir }Krishnakumar D. }Rejeeshnath } -- Sun Microsystems - India Engineering Centre http://blogs.sun.com/jkini