svn commit: r229601 - in stable/9/sys/dev: ce cp

Dimitry Andric dim at FreeBSD.org
Thu Jan 5 17:12:21 UTC 2012


Author: dim
Date: Thu Jan  5 17:12:20 2012
New Revision: 229601
URL: http://svn.freebsd.org/changeset/base/229601

Log:
  MFC r228963:
  
  Fix clang warnings in sys/dev/ce/if_ce.c and sys/dev/cp/if_cp.c,
  using jkim's last patch (reviewed by bde) from here:
  
  http://docs.freebsd.org/cgi/mid.cgi?201010141558.03154.jkim

Modified:
  stable/9/sys/dev/ce/if_ce.c
  stable/9/sys/dev/cp/if_cp.c
Directory Properties:
  stable/9/sys/   (props changed)

Modified: stable/9/sys/dev/ce/if_ce.c
==============================================================================
--- stable/9/sys/dev/ce/if_ce.c	Thu Jan  5 17:06:04 2012	(r229600)
+++ stable/9/sys/dev/ce/if_ce.c	Thu Jan  5 17:12:20 2012	(r229601)
@@ -1313,9 +1313,11 @@ static int ce_ioctl (struct cdev *dev, u
 			IFP2SP(d->ifp)->pp_flags &= ~(PP_FR);
 			IFP2SP(d->ifp)->pp_flags |= PP_KEEPALIVE;
 			d->ifp->if_flags |= PP_CISCO;
-		} else if (! strcmp ("fr", (char*)data) && PP_FR) {
+#if PP_FR != 0
+		} else if (! strcmp ("fr", (char*)data)) {
 			d->ifp->if_flags &= ~(PP_CISCO);
 			IFP2SP(d->ifp)->pp_flags |= PP_FR | PP_KEEPALIVE;
+#endif
 		} else if (! strcmp ("ppp", (char*)data)) {
 			IFP2SP(d->ifp)->pp_flags &= ~PP_FR;
 			IFP2SP(d->ifp)->pp_flags &= ~PP_KEEPALIVE;

Modified: stable/9/sys/dev/cp/if_cp.c
==============================================================================
--- stable/9/sys/dev/cp/if_cp.c	Thu Jan  5 17:06:04 2012	(r229600)
+++ stable/9/sys/dev/cp/if_cp.c	Thu Jan  5 17:12:20 2012	(r229601)
@@ -1052,9 +1052,11 @@ static int cp_ioctl (struct cdev *dev, u
 			IFP2SP(d->ifp)->pp_flags &= ~(PP_FR);
 			IFP2SP(d->ifp)->pp_flags |= PP_KEEPALIVE;
 			d->ifp->if_flags |= PP_CISCO;
-		} else if (! strcmp ("fr", (char*)data) && PP_FR) {
+#if PP_FR != 0
+		} else if (! strcmp ("fr", (char*)data)) {
 			d->ifp->if_flags &= ~(PP_CISCO);
 			IFP2SP(d->ifp)->pp_flags |= PP_FR | PP_KEEPALIVE;
+#endif
 		} else if (! strcmp ("ppp", (char*)data)) {
 			IFP2SP(d->ifp)->pp_flags &= ~PP_FR;
 			IFP2SP(d->ifp)->pp_flags &= ~PP_KEEPALIVE;


More information about the svn-src-stable-9 mailing list