summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usr/src/cmd/avs/dscfglockd/dscfglockd.c2
-rw-r--r--usr/src/cmd/format/menu_command.c3
-rw-r--r--usr/src/cmd/fs.d/ufs/mkfs/mkfs.c4
-rw-r--r--usr/src/cmd/mdb/intel/modules/generic_cpu/gcpu.c2
-rw-r--r--usr/src/cmd/scadm/sparc/mpxu/common/smq.c11
-rw-r--r--usr/src/cmd/troff/nroff.d/n6.c10
-rw-r--r--usr/src/cmd/troff/troff.d/t6.c26
-rw-r--r--usr/src/cmd/vi/port/ex.c4
-rw-r--r--usr/src/cmd/vi/port/ex.h22
-rw-r--r--usr/src/cmd/vi/port/ex_subr.c42
-rw-r--r--usr/src/lib/libefi/common/rdwr_efi.c2
-rw-r--r--usr/src/uts/common/io/hxge/hxge_virtual.c4
-rw-r--r--usr/src/uts/common/io/ib/adapters/hermon/hermon_cmd.c2
-rw-r--r--usr/src/uts/common/io/ib/adapters/tavor/tavor_cmd.c2
-rw-r--r--usr/src/uts/common/io/nxge/nxge_virtual.c4
-rw-r--r--usr/src/uts/common/sys/efi_partition.h3
-rw-r--r--usr/src/uts/common/sys/vtoc.h6
-rw-r--r--usr/src/uts/intel/io/dktp/drvobj/strategy.c12
-rw-r--r--usr/src/uts/sun4u/serengeti/io/sghsc.c4
19 files changed, 62 insertions, 103 deletions
diff --git a/usr/src/cmd/avs/dscfglockd/dscfglockd.c b/usr/src/cmd/avs/dscfglockd/dscfglockd.c
index f4fe71937a..578c38f15e 100644
--- a/usr/src/cmd/avs/dscfglockd/dscfglockd.c
+++ b/usr/src/cmd/avs/dscfglockd/dscfglockd.c
@@ -631,8 +631,6 @@ lock_stat()
struct lockdaemon *ldp;
int i;
- spcs_log("cfglockd", NULL,
- "%s, Lock daemon built %s **********", program, __DATE__);
switch (the_lock.type) {
case LOCK_NOTLOCKED:
lt = "not locked";
diff --git a/usr/src/cmd/format/menu_command.c b/usr/src/cmd/format/menu_command.c
index 6c77b086cf..0f5246a9c6 100644
--- a/usr/src/cmd/format/menu_command.c
+++ b/usr/src/cmd/format/menu_command.c
@@ -21,6 +21,7 @@
/*
* Copyright (c) 1993, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright 2012 Milan Jurik. All rights reserved.
+ * Copyright 2014 Toomas Soome <tsoome@me.com>
*/
/*
@@ -79,6 +80,8 @@ slist_t ptag_choices[] = {
{ "home", "", V_HOME },
{ "alternates", "", V_ALTSCTR },
{ "reserved", "", V_RESERVED },
+ { "system", "", V_SYSTEM },
+ { "BIOS_boot", "", V_BIOS_BOOT },
{ NULL }
};
diff --git a/usr/src/cmd/fs.d/ufs/mkfs/mkfs.c b/usr/src/cmd/fs.d/ufs/mkfs/mkfs.c
index 4fa2683a64..7d77e7a8b9 100644
--- a/usr/src/cmd/fs.d/ufs/mkfs/mkfs.c
+++ b/usr/src/cmd/fs.d/ufs/mkfs/mkfs.c
@@ -2810,7 +2810,7 @@ fsinit()
bcopy(&lost_found_dir[2], &buf[i], DIRSIZ(&lost_found_dir[2]));
}
node.i_number = LOSTFOUNDINO;
- node.i_smode = node.i_mode = IFDIR | 0700;
+ node.i_smode = IFDIR | 0700;
node.i_nlink = 2;
node.i_size = sblock.fs_bsize;
node.i_db[0] = alloc((int)node.i_size, node.i_mode);
@@ -2823,7 +2823,7 @@ fsinit()
* create the root directory
*/
node.i_number = UFSROOTINO;
- node.i_mode = node.i_smode = IFDIR | UMASK;
+ node.i_mode = IFDIR | UMASK;
node.i_nlink = PREDEFDIR;
node.i_size = makedir(root_dir, PREDEFDIR);
node.i_db[0] = alloc(sblock.fs_fsize, node.i_mode);
diff --git a/usr/src/cmd/mdb/intel/modules/generic_cpu/gcpu.c b/usr/src/cmd/mdb/intel/modules/generic_cpu/gcpu.c
index b097bba3f7..b43bfa236d 100644
--- a/usr/src/cmd/mdb/intel/modules/generic_cpu/gcpu.c
+++ b/usr/src/cmd/mdb/intel/modules/generic_cpu/gcpu.c
@@ -127,7 +127,7 @@ cmih_ent_next(struct cmih_walk_state *wsp)
return (B_TRUE);
/* increment the chip id */
- wsp->chipid = ++wsp->chipid & (CMI_MAX_CHIPID);
+ wsp->chipid = (wsp->chipid + 1) & (CMI_MAX_CHIPID);
return (B_TRUE);
}
diff --git a/usr/src/cmd/scadm/sparc/mpxu/common/smq.c b/usr/src/cmd/scadm/sparc/mpxu/common/smq.c
index ef267cc9f4..7e3434157a 100644
--- a/usr/src/cmd/scadm/sparc/mpxu/common/smq.c
+++ b/usr/src/cmd/scadm/sparc/mpxu/common/smq.c
@@ -24,8 +24,6 @@
* Use is subject to license terms.
*/
-#pragma ident "%Z%%M% %I% %E% SMI"
-
/*
* smq.c: to provide a message queue system for scadm functions (used in the
* firmware download context where BP messages, received from the service
@@ -91,8 +89,7 @@ smq_receive(smq_t *smq, smq_msg_t *msg)
/* Copy messaged into queue */
*msg = *smq->smq_head;
- /* Increment Head */
- smq->smq_head = smq->smq_head++;
+ smq->smq_head++;
if ((unsigned long)smq->smq_head > ((unsigned long)smq->smq_msgBuffer +
(unsigned long)(smq->smq_depth * sizeof (smq_msg_t)))) {
smq->smq_head = smq->smq_msgBuffer;
@@ -115,8 +112,7 @@ smq_send(smq_t *smq, smq_msg_t *msg)
/* Copy messaged into queue */
*smq->smq_tail = *msg;
- /* Increment Tail */
- smq->smq_tail = smq->smq_tail++;
+ smq->smq_tail++;
if ((unsigned long)smq->smq_tail > ((unsigned long)smq->smq_msgBuffer +
(unsigned long)(smq->smq_depth * sizeof (smq_msg_t)))) {
smq->smq_tail = smq->smq_msgBuffer;
@@ -175,8 +171,7 @@ smq_xreceive(smq_t *smq, timestruc_t *timeout, smq_msg_t *msg)
/* Copy messaged into queue */
*msg = *smq->smq_head;
- /* Increment Head */
- smq->smq_head = smq->smq_head++;
+ smq->smq_head++;
if ((unsigned long)smq->smq_head > ((unsigned long)smq->smq_msgBuffer +
(unsigned long)(smq->smq_depth * sizeof (smq_msg_t)))) {
smq->smq_head = smq->smq_msgBuffer;
diff --git a/usr/src/cmd/troff/nroff.d/n6.c b/usr/src/cmd/troff/nroff.d/n6.c
index ed6c394ff8..4098b23d69 100644
--- a/usr/src/cmd/troff/nroff.d/n6.c
+++ b/usr/src/cmd/troff/nroff.d/n6.c
@@ -37,8 +37,6 @@
* contributors.
*/
-#pragma ident "%Z%%M% %I% %E% SMI"
-
#include "tdef.h"
#include "tw.h"
#include "ext.h"
@@ -244,7 +242,7 @@ int a;
if (a)
i = getrq();
- else
+ else
i = getsn();
if (!i || i == 'P') {
j = font1;
@@ -271,7 +269,7 @@ setwd()
int delim, emsz, k;
int savhp, savapts, savapts1, savfont, savfont1, savpts, savpts1;
- base = numtab[ST].val = numtab[ST].val = wid = numtab[CT].val = 0;
+ base = numtab[ST].val = wid = numtab[CT].val = 0;
if (ismot(i = getch()))
return (0);
delim = cbits(i);
@@ -296,7 +294,7 @@ setwd()
k = -k;
base -= k;
emsz = 0;
- } else
+ } else
continue;
if (base < numtab[SB].val)
numtab[SB].val = base;
@@ -434,7 +432,7 @@ bd0:
if (skip() || !(i = getrq()) || (j = findft(i)) == -1) {
if (k)
goto bd1;
- else
+ else
return (0);
}
if (j == smnt) {
diff --git a/usr/src/cmd/troff/troff.d/t6.c b/usr/src/cmd/troff/troff.d/t6.c
index 771a01d9e3..3ce029c945 100644
--- a/usr/src/cmd/troff/troff.d/t6.c
+++ b/usr/src/cmd/troff/troff.d/t6.c
@@ -37,11 +37,9 @@
* contributors.
*/
-#pragma ident "%Z%%M% %I% %E% SMI"
-
/*
* t6.c
- *
+ *
* width functions, sizes and fonts
*/
@@ -98,7 +96,7 @@ tchar j;
if (sfbits(j) == oldbits) {
xfont = pfont;
xpts = ppts;
- } else
+ } else
xbits(j, 0);
if (widcache[i-32].fontpts == (xfont<<8) + xpts && !setwdf)
k = widcache[i-32].width;
@@ -186,8 +184,8 @@ int i;
if (cs = cstab[xfont]) {
nocache = 1;
if (ccs = ccstab[xfont])
- x = ccs;
- else
+ x = ccs;
+ else
x = xpts;
cs = (cs * EMPTS(x)) / 36;
}
@@ -472,7 +470,7 @@ int a;
if (a)
i = getrq();
- else
+ else
i = getsn();
if (!i || i == 'P') {
j = font1;
@@ -500,7 +498,7 @@ setwd()
int delim, emsz, k;
int savhp, savapts, savapts1, savfont, savfont1, savpts, savpts1;
- base = numtab[ST].val = numtab[ST].val = wid = numtab[CT].val = 0;
+ base = numtab[ST].val = wid = numtab[CT].val = 0;
if (ismot(i = getch()))
return (0);
delim = cbits(i);
@@ -525,7 +523,7 @@ setwd()
k = -k;
base -= k;
emsz = 0;
- } else
+ } else
continue;
if (base < numtab[SB].val)
numtab[SB].val = base;
@@ -640,7 +638,7 @@ tchar i;
*pbp++ = k;
j = LIG_FF;
}
- } else
+ } else
j = LIG_FF;
} else {
*pbp++ = j;
@@ -718,8 +716,8 @@ char *truename;
fontbase[pos]->nwfont = n; /* so can load a larger one again later */
close(k);
if (pos == smnt) {
- smnt = 0;
- sbold = 0;
+ smnt = 0;
+ sbold = 0;
}
if ((fontlab[pos] = f) == 'S')
smnt = pos;
@@ -776,7 +774,7 @@ bd0:
if (skip() || !(i = getrq()) || (j = findft(i)) == -1) {
if (k)
goto bd1;
- else
+ else
return (0);
}
if (j == smnt) {
@@ -810,7 +808,7 @@ casevs()
i = inumb(&lss);
if (nonumb)
i = lss1;
- if (i < VERT)
+ if (i < VERT)
i = VERT;
lss1 = lss;
lss = i;
diff --git a/usr/src/cmd/vi/port/ex.c b/usr/src/cmd/vi/port/ex.c
index 786242c21d..5475c23a2b 100644
--- a/usr/src/cmd/vi/port/ex.c
+++ b/usr/src/cmd/vi/port/ex.c
@@ -28,8 +28,6 @@
/* Copyright (c) 1981 Regents of the University of California */
-#pragma ident "%Z%%M% %I% %E% SMI"
-
#include "ex.h"
#include "ex_argv.h"
#include "ex_temp.h"
@@ -241,8 +239,6 @@ main(int ac, char *av[])
ruptible = signal(SIGINT, SIG_IGN) == SIG_DFL;
if (signal(SIGTERM, SIG_IGN) == SIG_DFL)
signal(SIGTERM, onhup);
- if (signal(SIGEMT, SIG_IGN) == SIG_DFL)
- signal(SIGEMT, onemt);
signal(SIGILL, oncore);
signal(SIGTRAP, oncore);
signal(SIGIOT, oncore);
diff --git a/usr/src/cmd/vi/port/ex.h b/usr/src/cmd/vi/port/ex.h
index 820937be46..65dc0edd01 100644
--- a/usr/src/cmd/vi/port/ex.h
+++ b/usr/src/cmd/vi/port/ex.h
@@ -366,8 +366,8 @@ var line *undadot; /* If we saved all lines, dot reverts here */
var int xflag; /* True if we are in encryption mode */
var int xtflag; /* True if the temp file is being encrypted */
var int kflag; /* True if the key has been accepted */
-var int crflag; /* True if the key has been accepted and the file
- being read is ciphertext
+var int crflag; /* True if the key has been accepted and the file
+ being read is ciphertext
*/
var int perm[2]; /* pipe connection to crypt for file being edited */
var int tperm[2]; /* pipe connection to crypt for temporary file */
@@ -379,7 +379,7 @@ char *getpass();
var bool write_quit; /* True if executing a 'wq' command */
var int errcnt; /* number of error/warning messages in */
- /* editing session (global flag) */
+ /* editing session (global flag) */
/*
* Function type definitions
*/
@@ -440,10 +440,9 @@ int normchar(wchar_t);
int normline(void);
int numbline(int);
var void (*oldquit)();
-#ifdef __STDC__
+
void onhup(int);
void onintr(int);
-void onemt(int);
void oncore(int);
#ifdef CBREAK
void vintr(int);
@@ -452,19 +451,6 @@ void onsusp(int);
int putch(char);
int plodput(char);
int vputch(char);
-#else
-void onhup();
-void onintr();
-void onemt();
-void oncore();
-#ifdef CBREAK
-void vintr();
-#endif
-void onsusp();
-int putch();
-int plodput();
-int vputch();
-#endif /* __STDC__ */
void shift(int, int);
int termchar(wchar_t);
diff --git a/usr/src/cmd/vi/port/ex_subr.c b/usr/src/cmd/vi/port/ex_subr.c
index ea3f4b3929..c920d55853 100644
--- a/usr/src/cmd/vi/port/ex_subr.c
+++ b/usr/src/cmd/vi/port/ex_subr.c
@@ -224,7 +224,7 @@ getmark(c)
int c;
{
line *addr;
-
+
for (addr = one; addr <= dol; addr++)
if (names[c - 'a'] == (*addr &~ 01)) {
return (addr);
@@ -576,7 +576,7 @@ qcolumn(unsigned char *lim, unsigned char *gp)
length = mbtowc(&wchar, (char *)lim, MULTI_BYTE_MAX);
if(length < 0)
length = 1;
- x = lim[length];
+ x = lim[length];
lim[length] = 0;
}
pline(0);
@@ -622,7 +622,7 @@ nqcolumn(unsigned char *lim, unsigned char *gp)
length = mbtowc(&wchar, (char *)lim, MULTI_BYTE_MAX);
if(length < 0)
length = 1;
- x = lim[length];
+ x = lim[length];
lim[length] = 0;
}
pline(0);
@@ -924,32 +924,6 @@ markit(line *addr)
}
/*
- * The following code is defensive programming against a bug in the
- * pdp-11 overlay implementation. Sometimes it goes nuts and asks
- * for an overlay with some garbage number, which generates an emt
- * trap. This is a less than elegant solution, but it is somewhat
- * better than core dumping and losing your work, leaving your tty
- * in a weird state, etc.
- */
-int _ovno;
-
-/*ARGSUSED*/
-void
-onemt(sig)
-int sig;
-{
- int oovno;
-
- signal(SIGEMT, onemt);
- oovno = _ovno;
- /* 2 and 3 are valid on 11/40 type vi, so */
- if (_ovno < 0 || _ovno > 3)
- _ovno = 0;
- error(value(vi_TERSE) ? gettext("emt trap, _ovno is %d ") :
-gettext("emt trap, _ovno is %d - try again"));
-}
-
-/*
* When a hangup occurs our actions are similar to a preserve
* command. If the buffer has not been [Modified], then we do
* nothing but remove the temporary files and exit.
@@ -961,7 +935,7 @@ gettext("emt trap, _ovno is %d - try again"));
*/
/*ARGSUSED*/
-void
+void
onhup(sig)
int sig;
{
@@ -1034,7 +1008,7 @@ int sig;
*/
/*ARGSUSED*/
-void
+void
onintr(sig)
int sig;
{
@@ -1123,7 +1097,7 @@ void exit(i)
extern void redraw();
/*ARGSUSED*/
-void
+void
onsusp(sig)
int sig;
{
@@ -1161,7 +1135,7 @@ int sig;
vdirty(0, lines);
if (sig)
vrepaint(cursor);
- }
+ }
}
#endif
@@ -1195,7 +1169,7 @@ unsigned char *linebuf, *cursor;
ccursor += length;
}
return(ocursor);
-}
+}
int
ixlatctl(int flag)
diff --git a/usr/src/lib/libefi/common/rdwr_efi.c b/usr/src/lib/libefi/common/rdwr_efi.c
index 96a75a443f..83dc815fbe 100644
--- a/usr/src/lib/libefi/common/rdwr_efi.c
+++ b/usr/src/lib/libefi/common/rdwr_efi.c
@@ -22,6 +22,7 @@
/*
* Copyright (c) 2002, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright 2012 Nexenta Systems, Inc. All rights reserved.
+ * Copyright 2014 Toomas Soome <tsoome@me.com>
*/
#include <stdio.h>
@@ -68,6 +69,7 @@ static struct uuid_to_ptag {
{ EFI_DELL_RESV },
{ EFI_AAPL_HFS },
{ EFI_AAPL_UFS },
+ { EFI_BIOS_BOOT },
{ EFI_FREEBSD_BOOT },
{ EFI_FREEBSD_SWAP },
{ EFI_FREEBSD_UFS },
diff --git a/usr/src/uts/common/io/hxge/hxge_virtual.c b/usr/src/uts/common/io/hxge/hxge_virtual.c
index f99c651934..435b848c58 100644
--- a/usr/src/uts/common/io/hxge/hxge_virtual.c
+++ b/usr/src/uts/common/io/hxge/hxge_virtual.c
@@ -935,8 +935,8 @@ hxge_ldgv_setup(p_hxge_ldg_t *ldgp, p_hxge_ldv_t *ldvp, uint8_t ldv,
HXGE_DEBUG_MSG((NULL, INT_CTL, "==> hxge_ldgv_setup(done): "
"ldv %d endldg %d ldg %d, ldvp $%p",
ldv, endldg, (*ldgp)->ldg, (*ldgp)->ldvp));
- (*ldvp) = ++*ldvp;
- (*ldgp) = ++*ldgp;
+ ++*ldvp;
+ ++*ldgp;
HXGE_DEBUG_MSG((NULL, INT_CTL,
"==> hxge_ldgv_setup: new ngrps %d", *ngrps));
}
diff --git a/usr/src/uts/common/io/ib/adapters/hermon/hermon_cmd.c b/usr/src/uts/common/io/ib/adapters/hermon/hermon_cmd.c
index 8de764d94b..7d2d886c37 100644
--- a/usr/src/uts/common/io/ib/adapters/hermon/hermon_cmd.c
+++ b/usr/src/uts/common/io/ib/adapters/hermon/hermon_cmd.c
@@ -697,7 +697,7 @@ hermon_impl_mbox_free(hermon_mboxlist_t *mblist, hermon_mbox_t **mb)
*/
if (mblist->mbl_pollers > 0 && mblist->mbl_waiters > 0) {
/* flip the signal value */
- mblist->mbl_signal = (++mblist->mbl_signal) % 2;
+ mblist->mbl_signal = (mblist->mbl_signal + 1) % 2;
} else if (mblist->mbl_waiters > 0) {
mblist->mbl_signal = 1;
} else {
diff --git a/usr/src/uts/common/io/ib/adapters/tavor/tavor_cmd.c b/usr/src/uts/common/io/ib/adapters/tavor/tavor_cmd.c
index 73fa04cc6f..4675367af6 100644
--- a/usr/src/uts/common/io/ib/adapters/tavor/tavor_cmd.c
+++ b/usr/src/uts/common/io/ib/adapters/tavor/tavor_cmd.c
@@ -676,7 +676,7 @@ tavor_impl_mbox_free(tavor_mboxlist_t *mblist, tavor_mbox_t **mb)
*/
if (mblist->mbl_pollers > 0 && mblist->mbl_waiters > 0) {
/* flip the signal value */
- mblist->mbl_signal = (++mblist->mbl_signal) % 2;
+ mblist->mbl_signal = (mblist->mbl_signal + 1) % 2;
} else if (mblist->mbl_waiters > 0) {
mblist->mbl_signal = 1;
} else {
diff --git a/usr/src/uts/common/io/nxge/nxge_virtual.c b/usr/src/uts/common/io/nxge/nxge_virtual.c
index f199e00c48..9305cb0d5c 100644
--- a/usr/src/uts/common/io/nxge/nxge_virtual.c
+++ b/usr/src/uts/common/io/nxge/nxge_virtual.c
@@ -3964,8 +3964,8 @@ nxge_ldgv_setup(p_nxge_ldg_t *ldgp, p_nxge_ldv_t *ldvp, uint8_t ldv,
NXGE_DEBUG_MSG((NULL, INT_CTL, "==> nxge_ldgv_setup(done): "
"ldv %d endldg %d ldg %d, ldvp $%p",
ldv, endldg, (*ldgp)->ldg, (*ldgp)->ldvp));
- (*ldvp) = ++*ldvp;
- (*ldgp) = ++*ldgp;
+ ++*ldvp;
+ ++*ldgp;
NXGE_DEBUG_MSG((NULL, INT_CTL,
"==> nxge_ldgv_setup: new ngrps %d", *ngrps));
}
diff --git a/usr/src/uts/common/sys/efi_partition.h b/usr/src/uts/common/sys/efi_partition.h
index 6de3bda39b..32d3d92b52 100644
--- a/usr/src/uts/common/sys/efi_partition.h
+++ b/usr/src/uts/common/sys/efi_partition.h
@@ -21,6 +21,7 @@
/*
* Copyright (c) 2002, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright 2012 Nexenta Systems, Inc. All rights reserved.
+ * Copyright 2014 Toomas Soome <tsoome@me.com>
*/
#ifndef _SYS_EFI_PARTITION_H
@@ -144,6 +145,8 @@ typedef struct efi_gpe_Attrs {
{ 0x00, 0x02, 0x2d, 0x09, 0x71, 0x2b } }
#define EFI_FREEBSD_ZFS { 0x516e7cba, 0x6ecf, 0x11d6, 0x8f, 0xf8, \
{ 0x00, 0x02, 0x2d, 0x09, 0x71, 0x2b } }
+#define EFI_BIOS_BOOT { 0x21686148, 0x6449, 0x6e6f, 0x74, 0x4e, \
+ { 0x65, 0x65, 0x64, 0x45, 0x46, 0x49 } }
/* minimum # of bytes for partition table entires, per EFI spec */
#define EFI_MIN_ARRAY_SIZE (16 * 1024)
diff --git a/usr/src/uts/common/sys/vtoc.h b/usr/src/uts/common/sys/vtoc.h
index ab6f56829d..cc0586a184 100644
--- a/usr/src/uts/common/sys/vtoc.h
+++ b/usr/src/uts/common/sys/vtoc.h
@@ -80,7 +80,13 @@ extern "C" {
#define V_HOME 0x08 /* Home partition */
#define V_ALTSCTR 0x09 /* Alternate sector partition */
#define V_CACHE 0x0a /* Cache (cachefs) partition */
+
+/* Tags for EFI/GPT labels */
#define V_RESERVED 0x0b /* SMI reserved data */
+#define V_SYSTEM 0x0c /* EFI/GPT system partition */
+#define V_BIOS_BOOT 0x18 /* BIOS Boot partition */
+
+#define V_UNKNOWN 0xff /* Unknown partition */
/*
* Partition permission flags
diff --git a/usr/src/uts/intel/io/dktp/drvobj/strategy.c b/usr/src/uts/intel/io/dktp/drvobj/strategy.c
index 16382da154..9d869ab110 100644
--- a/usr/src/uts/intel/io/dktp/drvobj/strategy.c
+++ b/usr/src/uts/intel/io/dktp/drvobj/strategy.c
@@ -235,7 +235,7 @@ dsngl_enque(opaque_t queuep, struct buf *in_bp)
kstat_waitq_enter(KSTAT_IO_PTR(dsnglp->ds_kstat));
}
if (TGCOM_PKT(tgcom_objp, in_bp, dsngl_restart,
- (caddr_t)dsnglp) != DDI_SUCCESS) {
+ (caddr_t)dsnglp) != DDI_SUCCESS) {
dsnglp->ds_bp = in_bp;
mutex_exit(&dsnglp->ds_mutex);
@@ -369,7 +369,7 @@ dmult_enque(opaque_t queuep, struct buf *in_bp)
}
if (TGCOM_PKT(tgcom_objp, in_bp, dmult_restart,
- (caddr_t)dmultp) != DDI_SUCCESS) {
+ (caddr_t)dmultp) != DDI_SUCCESS) {
dmultp->ds_bp = in_bp;
mutex_exit(&dmultp->ds_mutex);
@@ -859,7 +859,7 @@ qmerge_create()
queobjp->que_ops = &qmerge_ops;
qfp = (struct que_data *)(queobjp+1);
- qfp->q_tab.hd_private = qfp->q_tab.hd_private = 0;
+ qfp->q_tab.hd_private = 0;
qfp->q_tab.hd_sync_next = qfp->q_tab.hd_async_next = NULL;
qfp->q_tab.hd_cnt = (void *)qmerge_sync2async;
queobjp->que_data = (opaque_t)qfp;
@@ -1176,7 +1176,7 @@ begin_nextbp:
} else {
flags &= ~QNEAR_ASYNCALSO;
SYNC2ASYNC(qfp) =
- (void *)qmerge_sync2async;
+ (void *)qmerge_sync2async;
qfp->q_tab.hd_private = 0;
goto begin_nextbp;
}
@@ -1232,7 +1232,7 @@ begin_nextbp:
if (*async_bpp)
flags |= QNEAR_ASYNCALSO;
SYNC2ASYNC(qfp) =
- (void *)qmerge_sync2async;
+ (void *)qmerge_sync2async;
}
private = 0;
}
@@ -1250,7 +1250,7 @@ begin_nextbp:
if (*async_bpp)
flags |= QNEAR_ASYNCALSO;
SYNC2ASYNC(qfp) =
- (void *)qmerge_sync2async;
+ (void *)qmerge_sync2async;
}
}
} else if (qmerge2wayscan == 0) {
diff --git a/usr/src/uts/sun4u/serengeti/io/sghsc.c b/usr/src/uts/sun4u/serengeti/io/sghsc.c
index b2527630ee..f826a94bd2 100644
--- a/usr/src/uts/sun4u/serengeti/io/sghsc.c
+++ b/usr/src/uts/sun4u/serengeti/io/sghsc.c
@@ -1783,7 +1783,7 @@ sghsc_rb_put(sghsc_rb_head_t *rb_head, sghsc_event_t *event)
rb_head->buf[rb_head->put_idx] = *event;
- rb_head->put_idx = ++rb_head->put_idx & (rb_head->size - 1);
+ rb_head->put_idx = (rb_head->put_idx + 1) & (rb_head->size - 1);
if (rb_head->put_idx == rb_head->get_idx)
rb_head->state = SGHSC_RB_FULL;
@@ -1806,7 +1806,7 @@ sghsc_rb_get(sghsc_rb_head_t *rb_head, sghsc_event_t *event)
*event = rb_head->buf[rb_head->get_idx];
- rb_head->get_idx = ++rb_head->get_idx & (rb_head->size - 1);
+ rb_head->get_idx = (rb_head->get_idx + 1) & (rb_head->size - 1);
if (rb_head->get_idx == rb_head->put_idx)
rb_head->state = SGHSC_RB_EMPTY;