All of lore.kernel.org
 help / color / mirror / Atom feed
From: Artem Bityutskiy <dedekind1@gmail.com>
To: Xi Wang <xi.wang@gmail.com>
Cc: linux-mtd@lists.infradead.org, David Woodhouse <dwmw2@infradead.org>
Subject: Re: [PATCH] jffs2: refactor csize in jffs2_do_read_inode_internal()
Date: Mon, 23 Apr 2012 09:00:54 +0300	[thread overview]
Message-ID: <1335160854.28267.30.camel@brekeke> (raw)
In-Reply-To: <8EF5D079-1EBB-46D7-9A0A-A6054D94C958@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 653 bytes --]

On Mon, 2012-04-23 at 01:43 -0400, Xi Wang wrote:
> On Apr 22, 2012, at 7:57 AM, Artem Bityutskiy wrote:
> 
> > Please, introduce the variable in a separate patch.
> 
> Okay.
> 
> > WRT the csize check - you should compare it to something more sensible
> > than INT_MAX - try to dig the code and find out what is maximum value
> > JFFS2 expects. 
> 
> KMALLOC_MAX_SIZE - 1 is the smallest number I can find, since the code
> calls `kmalloc(csize + 1)'.  Does that look good?

I think JFFS2 has its own limit on the maximum size of the symlink
target. Probably it is PAGE_CACHE_SIZE, but not sure.

-- 
Best Regards,
Artem Bityutskiy

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  reply	other threads:[~2012-04-23  6:03 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-09 22:42 [PATCH] jffs2: refactor csize in jffs2_do_read_inode_internal() Xi Wang
2012-04-21 14:12 ` Artem Bityutskiy
2012-04-21 16:44   ` Xi Wang
2012-04-22 11:57 ` Artem Bityutskiy
2012-04-23  5:43   ` Xi Wang
2012-04-23  6:00     ` Artem Bityutskiy [this message]
2012-04-23  6:58       ` Xi Wang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1335160854.28267.30.camel@brekeke \
    --to=dedekind1@gmail.com \
    --cc=dwmw2@infradead.org \
    --cc=linux-mtd@lists.infradead.org \
    --cc=xi.wang@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.