mkreiserfs: move block_size_ok out of reiserfscore

block_size_ok is only used in mkreiserfs. We can pull it out of the
library.

Signed-off-by: Jeff Mahoney <jeffm@suse.com>
diff --git a/include/reiserfs_lib.h b/include/reiserfs_lib.h
index fb97293..18a6a3e 100644
--- a/include/reiserfs_lib.h
+++ b/include/reiserfs_lib.h
@@ -91,7 +91,6 @@
 void reiserfs_free_bitmap_blocks (reiserfs_filsys_t );
 */
 int no_reiserfs_found(reiserfs_filsys_t );
-int block_size_ok(int blocksize, int force);
 int is_block_count_correct(unsigned long block_of_super_block,
 			   unsigned int block_size, unsigned long block_count,
 			   unsigned long journal_size);
diff --git a/mkreiserfs/mkreiserfs.c b/mkreiserfs/mkreiserfs.c
index 21fd92d..889cda5 100644
--- a/mkreiserfs/mkreiserfs.c
+++ b/mkreiserfs/mkreiserfs.c
@@ -543,6 +543,30 @@
 	return REISERFS_FORMAT_3_5;
 }
 
+static int block_size_ok(int blocksize, int force)
+{
+	int pagesize = getpagesize();
+	if (blocksize > 4096) {
+		reiserfs_warning(stderr, "Block sizes larger than 4k are not "
+				 "supported on all architectures.\n");
+		if (blocksize > pagesize)
+			reiserfs_warning(stderr,
+					 "The newly created filesystem will not "
+					 "be mountable on this system.\n");
+		else
+			reiserfs_warning(stderr,
+					 "The newly created filesystem may not "
+					 "be mountable on other systems.\n");
+		check_forcing_ask_confirmation(force);
+	} else if (blocksize < 4096) {
+		reiserfs_warning(stderr, "Block sizes smaller than 4k "
+				 "are not supported.\n");
+		return 0;
+	}
+
+	return 1;
+}
+
 int main(int argc, char **argv)
 {
 	reiserfs_filsys_t fs;
diff --git a/reiserfscore/reiserfslib.c b/reiserfscore/reiserfslib.c
index 5c08ebb..53978d4 100644
--- a/reiserfscore/reiserfslib.c
+++ b/reiserfscore/reiserfslib.c
@@ -1227,30 +1227,6 @@
 			   &parent_root_dir_key, ih_flags);
 }
 
-int block_size_ok(int blocksize, int force)
-{
-	int pagesize = getpagesize();
-	if (blocksize > 4096) {
-		reiserfs_warning(stderr, "Block sizes larger than 4k are not "
-				 "supported on all architectures.\n");
-		if (blocksize > pagesize)
-			reiserfs_warning(stderr,
-					 "The newly created filesystem will not "
-					 "be mountable on this system.\n");
-		else
-			reiserfs_warning(stderr,
-					 "The newly created filesystem may not "
-					 "be mountable on other systems.\n");
-		check_forcing_ask_confirmation(force);
-	} else if (blocksize < 4096) {
-		reiserfs_warning(stderr, "Block sizes smaller than 4k "
-				 "are not supported.\n");
-		return 0;
-	}
-
-	return 1;
-}
-
 /* we only can use a file for filesystem or journal if it is either not
    mounted block device or regular file and we are forced to use it */
 int can_we_format_it(char *device_name, int force)