Rationalize visibility.

If it's C or POSIX, it's in. If it's BSD or GNU, it's guarded by __USE_BSD
or __USE_GNU.

Bug: https://code.google.com/p/android/issues/detail?id=194631
Change-Id: Ife51a21c2b37b060db56780d29c929805b199cb6
diff --git a/libc/include/limits.h b/libc/include/limits.h
index 7543567..84effa7 100644
--- a/libc/include/limits.h
+++ b/libc/include/limits.h
@@ -37,7 +37,6 @@
 
 #include <sys/cdefs.h>
 
-#if __XPG_VISIBLE
 #define PASS_MAX		128	/* _PASSWORD_LEN from <pwd.h> */
 
 #define NL_ARGMAX		9
@@ -48,7 +47,6 @@
 #define NL_TEXTMAX		255
 
 #define TMP_MAX                 308915776
-#endif /* __XPG_VISIBLE */
 
 #include <sys/limits.h>
 
@@ -68,14 +66,13 @@
 #define ULONG_LONG_MAX  ULLONG_MAX
 #endif
 
-/* BSD compatibility definitions. */
-#if __BSD_VISIBLE
+#if defined(__USE_BSD)
 #if defined(__LP64__)
 #define SIZE_T_MAX ULONG_MAX
 #else
 #define SIZE_T_MAX UINT_MAX
 #endif
-#endif /* __BSD_VISIBLE */
+#endif
 
 #if defined(__LP64__)
 #define SSIZE_MAX LONG_MAX