Artem Bityutskiy 6c0c42cdfd UBIFS: do not allocate too much
Bulk-read allocates 128KiB or more using kmalloc. The allocation
starts failing often when the memory gets fragmented. UBIFS still
works fine in this case, because it falls-back to standard
(non-optimized) read method, though. This patch teaches bulk-read
to allocate exactly the amount of memory it needs, instead of
allocating 128KiB every time.

This patch is also a preparation to the further fix where we'll
have a pre-allocated bulk-read buffer as well. For example, now
the @bu object is prepared in 'ubifs_bulk_read()', so we could
path either pre-allocated or allocated information to
'ubifs_do_bulk_read()' later. Or teaching 'ubifs_do_bulk_read()'
not to allocate 'bu->buf' if it is already there.

Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
2008-11-21 18:59:25 +02:00
..
2008-10-22 18:48:45 -05:00
2008-10-27 08:40:17 -07:00
2008-08-20 15:40:32 -07:00
2008-10-13 09:47:43 +11:00
2008-09-05 09:51:30 -05:00
2008-10-30 11:38:45 -07:00
2008-04-29 08:06:00 -07:00
2008-11-01 09:49:46 -07:00
2008-10-23 05:12:58 -04:00
2008-10-30 11:38:46 -07:00
2008-07-25 10:53:34 -07:00
2008-10-17 02:38:36 +11:00
2008-10-27 08:40:17 -07:00
2008-11-21 18:59:25 +02:00
2008-07-25 10:53:34 -07:00
2008-07-26 20:53:40 -04:00
2008-07-26 12:00:08 -07:00
2008-10-16 11:21:38 -07:00
2008-10-09 08:57:05 +02:00
2008-10-20 08:52:32 -07:00
2008-10-23 05:12:59 -04:00
2008-01-30 13:31:46 +01:00
2008-05-01 13:08:16 -04:00
2008-08-01 11:25:24 -04:00
2008-02-06 10:41:07 -08:00
2008-10-30 11:38:45 -07:00
2008-10-16 11:21:51 -07:00
2008-02-14 21:13:33 -08:00
2008-11-01 09:49:46 -07:00
2008-07-25 10:53:35 -07:00
2008-10-30 11:38:45 -07:00