From b4ccc9c5ebb4cc0ae0e0ca2d9bd6d6031fd4c38b Mon Sep 17 00:00:00 2001 From: Phillip Lougher Date: Wed, 13 May 2009 02:59:26 +0100 Subject: [PATCH] --- yaml --- r: 144914 b: refs/heads/master c: fffb47b80e8bb3f171ef02b90b1ae22c63983979 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/squashfs/super.c | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index e8c2a109b119..abea51074f2a 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a37b06d589f2c687a38d07569f4ef97c650fde39 +refs/heads/master: fffb47b80e8bb3f171ef02b90b1ae22c63983979 diff --git a/trunk/fs/squashfs/super.c b/trunk/fs/squashfs/super.c index ffa6edcd2d0c..0adc624c956f 100644 --- a/trunk/fs/squashfs/super.c +++ b/trunk/fs/squashfs/super.c @@ -157,6 +157,16 @@ static int squashfs_fill_super(struct super_block *sb, void *data, int silent) if (msblk->block_size > SQUASHFS_FILE_MAX_SIZE) goto failed_mount; + /* + * Check the system page size is not larger than the filesystem + * block size (by default 128K). This is currently not supported. + */ + if (PAGE_CACHE_SIZE > msblk->block_size) { + ERROR("Page size > filesystem block size (%d). This is " + "currently not supported!\n", msblk->block_size); + goto failed_mount; + } + msblk->block_log = le16_to_cpu(sblk->block_log); if (msblk->block_log > SQUASHFS_FILE_MAX_LOG) goto failed_mount;