lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sat, 30 Aug 2014 10:44:41 +0400
From:	Konstantin Khlebnikov <koct9i@...il.com>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	Konstantin Khlebnikov <k.khlebnikov@...sung.com>,
	"linux-mm@...ck.org" <linux-mm@...ck.org>,
	Rafael Aquini <aquini@...hat.com>,
	Sasha Levin <sasha.levin@...cle.com>,
	Andrey Ryabinin <ryabinin.a.a@...il.com>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 7/7] mm/balloon_compaction: general cleanup

On Sat, Aug 30, 2014 at 1:38 AM, Andrew Morton
<akpm@...ux-foundation.org> wrote:
> On Wed, 20 Aug 2014 19:05:09 +0400 Konstantin Khlebnikov <k.khlebnikov@...sung.com> wrote:
>
>> * move special branch for balloon migraion into migrate_pages
>> * remove special mapping for balloon and its flag AS_BALLOON_MAP
>> * embed struct balloon_dev_info into struct virtio_balloon
>> * cleanup balloon_page_dequeue, kill balloon_page_free
>
> Another testing failure.  Guys, allnoconfig is really fast.

Heh, mea culpa too. I've missed messages about including my patches except one
with stress-test, probably they are stuck somewhere in my corporate email.
So I thought you've picked only one patch.

Rafael had several suggestions so I postponed them till v2 patchset
which never been sent.

>
>> --- a/include/linux/balloon_compaction.h
>> +++ b/include/linux/balloon_compaction.h
>> @@ -54,58 +54,27 @@
>>   * balloon driver as a page book-keeper for its registered balloon devices.
>>   */
>>  struct balloon_dev_info {
>> -     void *balloon_device;           /* balloon device descriptor */
>> -     struct address_space *mapping;  /* balloon special page->mapping */
>>       unsigned long isolated_pages;   /* # of isolated pages for migration */
>>       spinlock_t pages_lock;          /* Protection to pages list */
>>       struct list_head pages;         /* Pages enqueued & handled to Host */
>> +     int (* migrate_page)(struct balloon_dev_info *, struct page *newpage,
>> +                     struct page *page, enum migrate_mode mode);
>>  };
>
> If CONFIG_MIGRATION=n this gets turned into "NULL" and chaos ensues.  I
> think I'll just nuke that #define:

Hmm, i think it's better to rename migrate_page() into something less generic.
for example generic_migrate_page() or generic_migratepage().

>
> --- a/include/linux/migrate.h~include-linux-migrateh-remove-migratepage-define
> +++ a/include/linux/migrate.h
> @@ -82,9 +82,6 @@ static inline int migrate_huge_page_move
>         return -ENOSYS;
>  }
>
> -/* Possible settings for the migrate_page() method in address_operations */
> -#define migrate_page NULL
> -
>  #endif /* CONFIG_MIGRATION */
>
>  #ifdef CONFIG_NUMA_BALANCING
> --- a/mm/swap_state.c~include-linux-migrateh-remove-migratepage-define
> +++ a/mm/swap_state.c
> @@ -28,7 +28,9 @@
>  static const struct address_space_operations swap_aops = {
>         .writepage      = swap_writepage,
>         .set_page_dirty = swap_set_page_dirty,
> +#ifdef CONFIG_MIGRATION
>         .migratepage    = migrate_page,
> +#endif
>  };
>
>  static struct backing_dev_info swap_backing_dev_info = {
> --- a/mm/shmem.c~include-linux-migrateh-remove-migratepage-define
> +++ a/mm/shmem.c
> @@ -3075,7 +3075,9 @@ static const struct address_space_operat
>         .write_begin    = shmem_write_begin,
>         .write_end      = shmem_write_end,
>  #endif
> +#ifdef CONFIG_MIGRATION
>         .migratepage    = migrate_page,
> +#endif
>         .error_remove_page = generic_error_remove_page,
>  };
>
>
> Our mixture of "migratepage" and "migrate_page" is maddening.
>
> --
> To unsubscribe, send a message with 'unsubscribe linux-mm' in
> the body to majordomo@...ck.org.  For more info on Linux MM,
> see: http://www.linux-mm.org/ .
> Don't email: <a href=mailto:"dont@...ck.org"> email@...ck.org </a>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ