Merge branch 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild
authorLinus Torvalds <torvalds@linux-foundation.org>
Wed, 20 Jan 2016 17:45:43 +0000 (09:45 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 20 Jan 2016 17:45:43 +0000 (09:45 -0800)
Pull kbuild updates from Michal Marek:
 - Make <modname>-m in makefiles work like <modname>-y and fix the
   fallout
 - Minor genksyms fix
 - Fix race with make -j install modules_install
 - Move -Wsign-compare from make W=1 to W=2
 - Other minor fixes

* 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
  kbuild: Demote 'sign-compare' warning to W=2
  Makefile: revert "Makefile: Document ability to make file.lst and file.S" partially
  kbuild: Do not run modules_install and install in paralel
  genksyms: Handle string literals with spaces in reference files
  fixdep: constify strrcmp arguments
  ath10k: Fix build with CONFIG_THERMAL=m
  Revert "drm: Hack around CONFIG_AGP=m build failures"
  kbuild: Allow to specify composite modules with modname-m
  staging/ad7606: Actually build the interface modules

1  2 
Makefile
drivers/gpu/drm/Makefile
fs/logfs/logfs.h
scripts/Makefile.lib

diff --combined Makefile
index 70dea02f1346d4fa8253fb4d22aac60c7718e0c7,c8c36cef7e3990baacde9c308b113465ac994b61..7f4ac1ee4a2b1359276b7f49b87008a5b4b6b413
+++ b/Makefile
@@@ -1,7 -1,7 +1,7 @@@
  VERSION = 4
  PATCHLEVEL = 4
  SUBLEVEL = 0
 -EXTRAVERSION = -rc1
 +EXTRAVERSION =
  NAME = Blurry Fish Butt
  
  # *DOCUMENTATION*
@@@ -495,6 -495,12 +495,12 @@@ ifeq ($(KBUILD_EXTMOD),
                  endif
          endif
  endif
+ # install and module_install need also be processed one by one
+ ifneq ($(filter install,$(MAKECMDGOALS)),)
+         ifneq ($(filter modules_install,$(MAKECMDGOALS)),)
+               mixed-targets := 1
+         endif
+ endif
  
  ifeq ($(mixed-targets),1)
  # ===========================================================================
@@@ -1259,7 -1265,7 +1265,7 @@@ help
        @echo  '  firmware_install- Install all firmware to INSTALL_FW_PATH'
        @echo  '                    (default: $$(INSTALL_MOD_PATH)/lib/firmware)'
        @echo  '  dir/            - Build all files in dir and below'
-       @echo  '  dir/file.[oisS] - Build specified target only'
+       @echo  '  dir/file.[ois - Build specified target only'
        @echo  '  dir/file.lst    - Build specified mixed source/assembly target only'
        @echo  '                    (requires a recent binutils and recent build (System.map))'
        @echo  '  dir/file.ko     - Build module including final link'
diff --combined drivers/gpu/drm/Makefile
index 8727d841bfd29b825ae25040c9cff025e85b4c69,3bfab260ba45c7e06d5f2986e5e8e1c1f2252eca..61766dec6a8d3d7a4e9282b740161145818a51bc
@@@ -21,8 -21,6 +21,6 @@@ drm-$(CONFIG_DRM_PANEL) += drm_panel.
  drm-$(CONFIG_OF) += drm_of.o
  drm-$(CONFIG_AGP) += drm_agpsupport.o
  
- drm-y += $(drm-m)
  drm_kms_helper-y := drm_crtc_helper.o drm_dp_helper.o drm_probe_helper.o \
                drm_plane_helper.o drm_dp_mst_topology.o drm_atomic_helper.o
  drm_kms_helper-$(CONFIG_DRM_LOAD_EDID_FIRMWARE) += drm_edid_load.o
@@@ -62,7 -60,7 +60,7 @@@ obj-$(CONFIG_DRM_ARMADA) += armada
  obj-$(CONFIG_DRM_ATMEL_HLCDC) += atmel-hlcdc/
  obj-$(CONFIG_DRM_RCAR_DU) += rcar-du/
  obj-$(CONFIG_DRM_SHMOBILE) +=shmobile/
 -obj-$(CONFIG_DRM_OMAP)        += omapdrm/
 +obj-y                 += omapdrm/
  obj-y                 += tilcdc/
  obj-$(CONFIG_DRM_QXL) += qxl/
  obj-$(CONFIG_DRM_BOCHS) += bochs/
@@@ -75,4 -73,3 +73,4 @@@ obj-y                 += i2c
  obj-y                 += panel/
  obj-y                 += bridge/
  obj-$(CONFIG_DRM_FSL_DCU) += fsl-dcu/
 +obj-$(CONFIG_DRM_ETNAVIV) += etnaviv/
diff --combined fs/logfs/logfs.h
index 39d91f86cd357ea12f38c4406d6bb12a4a5de8c5,23f961a8fb92211d7324089ed14de66a92a41a9d..27d040e35faa9d01b57649aa498869960e270d02
@@@ -302,7 -302,7 +302,7 @@@ struct logfs_block 
        struct inode *inode;
        struct logfs_transaction *ta;
        unsigned long alias_map[LOGFS_BLOCK_FACTOR / BITS_PER_LONG];
 -      struct logfs_block_ops *ops;
 +      const struct logfs_block_ops *ops;
        int full;
        int partial;
        int reserved_bytes;
@@@ -485,7 -485,7 +485,7 @@@ static inline int logfs_get_sb_bdev(str
  #endif
  
  /* dev_mtd.c */
- #ifdef CONFIG_MTD
+ #if IS_ENABLED(CONFIG_MTD)
  int logfs_get_sb_mtd(struct logfs_super *s, int mtdnr);
  #else
  static inline int logfs_get_sb_mtd(struct logfs_super *s, int mtdnr)
  #endif
  
  /* dir.c */
 -extern const struct inode_operations logfs_symlink_iops;
  extern const struct inode_operations logfs_dir_iops;
  extern const struct file_operations logfs_dir_fops;
  int logfs_replay_journal(struct super_block *sb);
@@@ -578,7 -579,7 +578,7 @@@ int logfs_exist_block(struct inode *ino
  int get_page_reserve(struct inode *inode, struct page *page);
  void logfs_get_wblocks(struct super_block *sb, struct page *page, int lock);
  void logfs_put_wblocks(struct super_block *sb, struct page *page, int lock);
 -extern struct logfs_block_ops indirect_block_ops;
 +extern const struct logfs_block_ops indirect_block_ops;
  
  /* segment.c */
  int logfs_erase_segment(struct super_block *sb, u32 ofs, int ensure_erase);
diff --combined scripts/Makefile.lib
index 26a48d76eb9d08f4d5001a09bbf3a359aa41139d,e18957b7a83029951fd975cb8d5de9aeaec65bdc..39d6bb18ce7669fc8b0ea79978cddee1b44b8fc5
@@@ -48,7 -48,7 +48,7 @@@ subdir-ym     := $(sort $(subdir-y) $(subdi
  
  # if $(foo-objs) exists, foo.o is a composite object
  multi-used-y := $(sort $(foreach m,$(obj-y), $(if $(strip $($(m:.o=-objs)) $($(m:.o=-y))), $(m))))
- multi-used-m := $(sort $(foreach m,$(obj-m), $(if $(strip $($(m:.o=-objs)) $($(m:.o=-y))), $(m))))
+ multi-used-m := $(sort $(foreach m,$(obj-m), $(if $(strip $($(m:.o=-objs)) $($(m:.o=-y)) $($(m:.o=-m))), $(m))))
  multi-used   := $(multi-used-y) $(multi-used-m)
  single-used-m := $(sort $(filter-out $(multi-used-m),$(obj-m)))
  
@@@ -67,7 -67,7 +67,7 @@@ obj-dirs := $(dir $(multi-objs) $(obj-y
  
  # Replace multi-part objects by their individual parts, look at local dir only
  real-objs-y := $(foreach m, $(filter-out $(subdir-obj-y), $(obj-y)), $(if $(strip $($(m:.o=-objs)) $($(m:.o=-y))),$($(m:.o=-objs)) $($(m:.o=-y)),$(m))) $(extra-y)
- real-objs-m := $(foreach m, $(obj-m), $(if $(strip $($(m:.o=-objs)) $($(m:.o=-y))),$($(m:.o=-objs)) $($(m:.o=-y)),$(m)))
+ real-objs-m := $(foreach m, $(obj-m), $(if $(strip $($(m:.o=-objs)) $($(m:.o=-y)) $($(m:.o=-m))),$($(m:.o=-objs)) $($(m:.o=-y)) $($(m:.o=-m)),$(m)))
  
  # Add subdir path
  
@@@ -104,9 -104,8 +104,9 @@@ modname_flags  = $(if $(filter 1,$(word
  orig_c_flags   = $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS) $(KBUILD_SUBDIR_CCFLAGS) \
                   $(ccflags-y) $(CFLAGS_$(basetarget).o)
  _c_flags       = $(filter-out $(CFLAGS_REMOVE_$(basetarget).o), $(orig_c_flags))
 -_a_flags       = $(KBUILD_CPPFLAGS) $(KBUILD_AFLAGS) $(KBUILD_SUBDIR_ASFLAGS) \
 +orig_a_flags   = $(KBUILD_CPPFLAGS) $(KBUILD_AFLAGS) $(KBUILD_SUBDIR_ASFLAGS) \
                   $(asflags-y) $(AFLAGS_$(basetarget).o)
 +_a_flags       = $(filter-out $(AFLAGS_REMOVE_$(basetarget).o), $(orig_a_flags))
  _cpp_flags     = $(KBUILD_CPPFLAGS) $(cppflags-y) $(CPPFLAGS_$(@F))
  
  #