]> git.openfabrics.org - ~emulex/infiniband.git/commitdiff
tty: Remove private constant from global namespace
authorPeter Hurley <peter@hurleysoftware.com>
Sat, 15 Jun 2013 13:36:16 +0000 (09:36 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 23 Jul 2013 23:47:10 +0000 (16:47 -0700)
TTY_BUFFER_PAGE is only used within drivers/tty/tty_buffer.c;
relocate to that file scope.

Signed-off-by: Peter Hurley <peter@hurleysoftware.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/tty_buffer.c
include/linux/tty.h

index f22e116db105df51990d1abfb7231b9fe9f29b25..c043136fbe5198cf0a7a8704254fc28763ecd0b9 100644 (file)
  */
 #define TTYB_MEM_LIMIT 65536
 
+/*
+ * We default to dicing tty buffer allocations to this many characters
+ * in order to avoid multiple page allocations. We know the size of
+ * tty_buffer itself but it must also be taken into account that the
+ * the buffer is 256 byte aligned. See tty_buffer_find for the allocation
+ * logic this must match
+ */
+
+#define TTY_BUFFER_PAGE        (((PAGE_SIZE - sizeof(struct tty_buffer)) / 2) & ~0xFF)
+
 
 /**
  *     tty_buffer_lock_exclusive       -       gain exclusive access to buffer
index 7a9a3b0a6b5a2af23bd4b8c242fb08b617d33bb1..5fd5d6f1ebc40fb2042f52c762ad0d8139476cec 100644 (file)
@@ -53,17 +53,6 @@ static inline char *flag_buf_ptr(struct tty_buffer *b, int ofs)
        return (char *)char_buf_ptr(b, ofs) + b->size;
 }
 
-/*
- * We default to dicing tty buffer allocations to this many characters
- * in order to avoid multiple page allocations. We know the size of
- * tty_buffer itself but it must also be taken into account that the
- * the buffer is 256 byte aligned. See tty_buffer_find for the allocation
- * logic this must match
- */
-
-#define TTY_BUFFER_PAGE        (((PAGE_SIZE - sizeof(struct tty_buffer)) / 2) & ~0xFF)
-
-
 struct tty_bufhead {
        struct tty_buffer *head;        /* Queue head */
        struct work_struct work;