All of lore.kernel.org
 help / color / mirror / Atom feed
* CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
@ 2011-01-12 20:10 ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-12 20:10 UTC (permalink / raw)
  To: linux-kernel, linux-next, jbarnes, sfr
  Cc: Matt_Domsch, Charles_Rose, Surya_Prabhakar

Hello,

As described in the post http://marc.info/?l=linux-next&m=129478755528194&w=2
setting CONFIG_NLS=m (generated by 'make allmodconfig) is causing a build
failure on linux-next as following while compiling the patch 
http://marc.info/?l=linux-pci&m=129313294112736&w=1 ([PATCH V2] Export
ACPI _DSM provided firmware instance number and string to sysfs)

drivers/built-in.o: In function `dsm_label_utf16s_to_utf8s':
/usr/src/Linux-Next/linux-next/drivers/pci/pci-label.c:195: undefined reference to `utf16s_to_utf8s'
make: *** [.tmp_vmlinux1] Error 1

The drivers/pci/pci-label.c is compiled as part of vmlinux as defined by
the makefile drivers/pci/Makefile. 

#
# ACPI Related PCI FW Functions
# ACPI _DSM provided firmware instance and string name
#
obj-$(CONFIG_ACPI)    += pci-acpi.o pci-label.o

# SMBIOS provided firmware instance and labels
obj-$(CONFIG_DMI)    += pci-label.o

This could be prevented by one of the following methods -

* forcing CONFIG_NLS=y if CONFIG_PCI=y 
* move `utf16s_to_utf8s' out of nls_base.c to a new file to be always
built into vmlinux

Please correct me if i missed something here and let me know what would be the right
way to fix this build failure.

With regards,
Narendra K






^ permalink raw reply	[flat|nested] 31+ messages in thread

* CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
@ 2011-01-12 20:10 ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-12 20:10 UTC (permalink / raw)
  To: linux-kernel, linux-next, jbarnes, sfr
  Cc: Matt_Domsch, Charles_Rose, Surya_Prabhakar

Hello,

As described in the post http://marc.info/?l=linux-next&m=129478755528194&w=2
setting CONFIG_NLS=m (generated by 'make allmodconfig) is causing a build
failure on linux-next as following while compiling the patch 
http://marc.info/?l=linux-pci&m=129313294112736&w=1 ([PATCH V2] Export
ACPI _DSM provided firmware instance number and string to sysfs)

drivers/built-in.o: In function `dsm_label_utf16s_to_utf8s':
/usr/src/Linux-Next/linux-next/drivers/pci/pci-label.c:195: undefined reference to `utf16s_to_utf8s'
make: *** [.tmp_vmlinux1] Error 1

The drivers/pci/pci-label.c is compiled as part of vmlinux as defined by
the makefile drivers/pci/Makefile. 

#
# ACPI Related PCI FW Functions
# ACPI _DSM provided firmware instance and string name
#
obj-$(CONFIG_ACPI)    += pci-acpi.o pci-label.o

# SMBIOS provided firmware instance and labels
obj-$(CONFIG_DMI)    += pci-label.o

This could be prevented by one of the following methods -

* forcing CONFIG_NLS=y if CONFIG_PCI=y 
* move `utf16s_to_utf8s' out of nls_base.c to a new file to be always
built into vmlinux

Please correct me if i missed something here and let me know what would be the right
way to fix this build failure.

With regards,
Narendra K

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
  2011-01-12 20:10 ` Narendra_K
@ 2011-01-13  0:02   ` Jesse Barnes
  -1 siblings, 0 replies; 31+ messages in thread
From: Jesse Barnes @ 2011-01-13  0:02 UTC (permalink / raw)
  To: Narendra_K
  Cc: linux-kernel, linux-next, sfr, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Wed, 12 Jan 2011 12:10:17 -0800
<Narendra_K@Dell.com> wrote:

> Hello,
> 
> As described in the post http://marc.info/?l=linux-next&m=129478755528194&w=2
> setting CONFIG_NLS=m (generated by 'make allmodconfig) is causing a build
> failure on linux-next as following while compiling the patch 
> http://marc.info/?l=linux-pci&m=129313294112736&w=1 ([PATCH V2] Export
> ACPI _DSM provided firmware instance number and string to sysfs)
> 
> drivers/built-in.o: In function `dsm_label_utf16s_to_utf8s':
> /usr/src/Linux-Next/linux-next/drivers/pci/pci-label.c:195: undefined reference to `utf16s_to_utf8s'
> make: *** [.tmp_vmlinux1] Error 1
> 
> The drivers/pci/pci-label.c is compiled as part of vmlinux as defined by
> the makefile drivers/pci/Makefile. 
> 
> #
> # ACPI Related PCI FW Functions
> # ACPI _DSM provided firmware instance and string name
> #
> obj-$(CONFIG_ACPI)    += pci-acpi.o pci-label.o
> 
> # SMBIOS provided firmware instance and labels
> obj-$(CONFIG_DMI)    += pci-label.o
> 
> This could be prevented by one of the following methods -
> 
> * forcing CONFIG_NLS=y if CONFIG_PCI=y 
> * move `utf16s_to_utf8s' out of nls_base.c to a new file to be always
> built into vmlinux
> 
> Please correct me if i missed something here and let me know what would be the right
> way to fix this build failure.

So there's no other ACPI code that depends on this function?  I'd hate
to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
case the select or depend should be there), I guess it should be pulled
into a common file that will always be included.

Thanks,
-- 
Jesse Barnes, Intel Open Source Technology Center

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
@ 2011-01-13  0:02   ` Jesse Barnes
  0 siblings, 0 replies; 31+ messages in thread
From: Jesse Barnes @ 2011-01-13  0:02 UTC (permalink / raw)
  To: Narendra_K
  Cc: linux-kernel, linux-next, sfr, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Wed, 12 Jan 2011 12:10:17 -0800
<Narendra_K@Dell.com> wrote:

> Hello,
> 
> As described in the post http://marc.info/?l=linux-next&m=129478755528194&w=2
> setting CONFIG_NLS=m (generated by 'make allmodconfig) is causing a build
> failure on linux-next as following while compiling the patch 
> http://marc.info/?l=linux-pci&m=129313294112736&w=1 ([PATCH V2] Export
> ACPI _DSM provided firmware instance number and string to sysfs)
> 
> drivers/built-in.o: In function `dsm_label_utf16s_to_utf8s':
> /usr/src/Linux-Next/linux-next/drivers/pci/pci-label.c:195: undefined reference to `utf16s_to_utf8s'
> make: *** [.tmp_vmlinux1] Error 1
> 
> The drivers/pci/pci-label.c is compiled as part of vmlinux as defined by
> the makefile drivers/pci/Makefile. 
> 
> #
> # ACPI Related PCI FW Functions
> # ACPI _DSM provided firmware instance and string name
> #
> obj-$(CONFIG_ACPI)    += pci-acpi.o pci-label.o
> 
> # SMBIOS provided firmware instance and labels
> obj-$(CONFIG_DMI)    += pci-label.o
> 
> This could be prevented by one of the following methods -
> 
> * forcing CONFIG_NLS=y if CONFIG_PCI=y 
> * move `utf16s_to_utf8s' out of nls_base.c to a new file to be always
> built into vmlinux
> 
> Please correct me if i missed something here and let me know what would be the right
> way to fix this build failure.

So there's no other ACPI code that depends on this function?  I'd hate
to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
case the select or depend should be there), I guess it should be pulled
into a common file that will always be included.

Thanks,
-- 
Jesse Barnes, Intel Open Source Technology Center

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
  2011-01-13  0:02   ` Jesse Barnes
  (?)
@ 2011-01-13  3:23   ` Len Brown
  2011-01-13 15:55     ` Jesse Barnes
  2011-01-13 16:46       ` Narendra_K
  -1 siblings, 2 replies; 31+ messages in thread
From: Len Brown @ 2011-01-13  3:23 UTC (permalink / raw)
  To: Jesse Barnes
  Cc: Narendra_K, linux-kernel, linux-next, sfr, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar


> > drivers/built-in.o: In function `dsm_label_utf16s_to_utf8s':
> > /usr/src/Linux-Next/linux-next/drivers/pci/pci-label.c:195: undefined reference to `utf16s_to_utf8s'
> > make: *** [.tmp_vmlinux1] Error 1
> > 
> > The drivers/pci/pci-label.c is compiled as part of vmlinux as defined by
> > the makefile drivers/pci/Makefile. 
> > 
> > #
> > # ACPI Related PCI FW Functions
> > # ACPI _DSM provided firmware instance and string name
> > #
> > obj-$(CONFIG_ACPI)    += pci-acpi.o pci-label.o
> > 
> > # SMBIOS provided firmware instance and labels
> > obj-$(CONFIG_DMI)    += pci-label.o
> > 
> > This could be prevented by one of the following methods -
> > 
> > * forcing CONFIG_NLS=y if CONFIG_PCI=y 
> > * move `utf16s_to_utf8s' out of nls_base.c to a new file to be always
> > built into vmlinux
> > 
> > Please correct me if i missed something here and let me know what would be the right
> > way to fix this build failure.
> 
> So there's no other ACPI code that depends on this function?  I'd hate
> to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
> case the select or depend should be there), I guess it should be pulled
> into a common file that will always be included.

No, nothing in the ACPI code uses utf16s_to_utf8s.

I don't know anything about NLS, but it appears to be
something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
use to to support native languages.

BTW. I don't understand why pci-label.o appears twice above.
It used to be just the 2nd one, that depends on CONFIG_DMI.

cheers,
Len Brown, Intel Open Source Technology Center



^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
  2011-01-13  3:23   ` Len Brown
@ 2011-01-13 15:55     ` Jesse Barnes
  2011-01-13 16:03         ` Narendra_K
  2011-01-13 16:46       ` Narendra_K
  1 sibling, 1 reply; 31+ messages in thread
From: Jesse Barnes @ 2011-01-13 15:55 UTC (permalink / raw)
  To: Len Brown
  Cc: Narendra_K, linux-kernel, linux-next, sfr, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

On Wed, 12 Jan 2011 22:23:55 -0500 (EST)
Len Brown <lenb@kernel.org> wrote:
> > So there's no other ACPI code that depends on this function?  I'd hate
> > to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
> > case the select or depend should be there), I guess it should be pulled
> > into a common file that will always be included.
> 
> No, nothing in the ACPI code uses utf16s_to_utf8s.
> 
> I don't know anything about NLS, but it appears to be
> something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
> use to to support native languages.
> 
> BTW. I don't understand why pci-label.o appears twice above.
> It used to be just the 2nd one, that depends on CONFIG_DMI.

Ok, I'll drop this patch for now then since I haven't seen a fix yet
and need to get Linus the rest of the changes.

Thanks,
Jesse

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
  2011-01-13 15:55     ` Jesse Barnes
@ 2011-01-13 16:03         ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-13 16:03 UTC (permalink / raw)
  To: jbarnes
  Cc: lenb, linux-kernel, linux-next, sfr, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Thu, Jan 13, 2011 at 09:25:56PM +0530, Jesse Barnes wrote:
> On Wed, 12 Jan 2011 22:23:55 -0500 (EST)
> Len Brown <lenb@kernel.org> wrote:
> > > So there's no other ACPI code that depends on this function?  I'd hate
> > > to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
> > > case the select or depend should be there), I guess it should be pulled
> > > into a common file that will always be included.
> > 
> > No, nothing in the ACPI code uses utf16s_to_utf8s.
> > 
> > I don't know anything about NLS, but it appears to be
> > something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
> > use to to support native languages.
> > 
> > BTW. I don't understand why pci-label.o appears twice above.
> > It used to be just the 2nd one, that depends on CONFIG_DMI.
> 
> Ok, I'll drop this patch for now then since I haven't seen a fix yet
> and need to get Linus the rest of the changes.

Jesse,

I just compile tested a fix on the following lines without any failure.
If it is acceptable, i will send a patch in half an hour. It builds

diff --git a/fs/Makefile b/fs/Makefile
index db71a5b..2a39275 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
 obj-$(CONFIG_EXPORTFS)		+= exportfs/
 obj-$(CONFIG_NFSD)		+= nfsd/
 obj-$(CONFIG_LOCKD)		+= lockd/
-obj-$(CONFIG_NLS)		+= nls/
+obj-y				+= nls/
 obj-$(CONFIG_SYSV_FS)		+= sysv/
 obj-$(CONFIG_CIFS)		+= cifs/
 obj-$(CONFIG_NCP_FS)		+= ncpfs/
diff --git a/fs/nls/Makefile b/fs/nls/Makefile
index f499dd7..c172fbb 100644
--- a/fs/nls/Makefile
+++ b/fs/nls/Makefile
@@ -2,7 +2,7 @@
 # Makefile for native language support
 #
 
-obj-$(CONFIG_NLS)		+= nls_base.o
+obj-y				+= nls_base.o
 
 obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
 obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o

With regards,
Narendra K

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* Re: CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
@ 2011-01-13 16:03         ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-13 16:03 UTC (permalink / raw)
  To: jbarnes
  Cc: lenb, linux-kernel, linux-next, sfr, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Thu, Jan 13, 2011 at 09:25:56PM +0530, Jesse Barnes wrote:
> On Wed, 12 Jan 2011 22:23:55 -0500 (EST)
> Len Brown <lenb@kernel.org> wrote:
> > > So there's no other ACPI code that depends on this function?  I'd hate
> > > to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
> > > case the select or depend should be there), I guess it should be pulled
> > > into a common file that will always be included.
> > 
> > No, nothing in the ACPI code uses utf16s_to_utf8s.
> > 
> > I don't know anything about NLS, but it appears to be
> > something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
> > use to to support native languages.
> > 
> > BTW. I don't understand why pci-label.o appears twice above.
> > It used to be just the 2nd one, that depends on CONFIG_DMI.
> 
> Ok, I'll drop this patch for now then since I haven't seen a fix yet
> and need to get Linus the rest of the changes.

Jesse,

I just compile tested a fix on the following lines without any failure.
If it is acceptable, i will send a patch in half an hour. It builds

diff --git a/fs/Makefile b/fs/Makefile
index db71a5b..2a39275 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
 obj-$(CONFIG_EXPORTFS)		+= exportfs/
 obj-$(CONFIG_NFSD)		+= nfsd/
 obj-$(CONFIG_LOCKD)		+= lockd/
-obj-$(CONFIG_NLS)		+= nls/
+obj-y				+= nls/
 obj-$(CONFIG_SYSV_FS)		+= sysv/
 obj-$(CONFIG_CIFS)		+= cifs/
 obj-$(CONFIG_NCP_FS)		+= ncpfs/
diff --git a/fs/nls/Makefile b/fs/nls/Makefile
index f499dd7..c172fbb 100644
--- a/fs/nls/Makefile
+++ b/fs/nls/Makefile
@@ -2,7 +2,7 @@
 # Makefile for native language support
 #
 
-obj-$(CONFIG_NLS)		+= nls_base.o
+obj-y				+= nls_base.o
 
 obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
 obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o

With regards,
Narendra K

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* Re: CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
  2011-01-13  3:23   ` Len Brown
@ 2011-01-13 16:46       ` Narendra_K
  2011-01-13 16:46       ` Narendra_K
  1 sibling, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-13 16:46 UTC (permalink / raw)
  To: lenb
  Cc: jbarnes, linux-kernel, linux-next, sfr, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

On Thu, Jan 13, 2011 at 08:53:55AM +0530, Len Brown wrote:
> 
> > > drivers/built-in.o: In function `dsm_label_utf16s_to_utf8s':
> > > /usr/src/Linux-Next/linux-next/drivers/pci/pci-label.c:195: undefined reference to `utf16s_to_utf8s'
> > > make: *** [.tmp_vmlinux1] Error 1
> > > 
> > > The drivers/pci/pci-label.c is compiled as part of vmlinux as defined by
> > > the makefile drivers/pci/Makefile. 
> > > 
> > > #
> > > # ACPI Related PCI FW Functions
> > > # ACPI _DSM provided firmware instance and string name
> > > #
> > > obj-$(CONFIG_ACPI)    += pci-acpi.o pci-label.o
> > > 
> > > # SMBIOS provided firmware instance and labels
> > > obj-$(CONFIG_DMI)    += pci-label.o
> > > 
> > > This could be prevented by one of the following methods -
> > > 
> > > * forcing CONFIG_NLS=y if CONFIG_PCI=y 
> > > * move `utf16s_to_utf8s' out of nls_base.c to a new file to be always
> > > built into vmlinux
> > > 
> > > Please correct me if i missed something here and let me know what would be the right
> > > way to fix this build failure.
> > 
> > So there's no other ACPI code that depends on this function?  I'd hate
> > to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
> > case the select or depend should be there), I guess it should be pulled
> > into a common file that will always be included.
> 
> No, nothing in the ACPI code uses utf16s_to_utf8s.

Len,

Thanks for the information.

> 
> I don't know anything about NLS, but it appears to be
> something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
> use to to support native languages.
> 
> BTW. I don't understand why pci-label.o appears twice above.
> It used to be just the 2nd one, that depends on CONFIG_DMI.
> 

Support has been added to export ACPI _DSM provided firmware instance
number and string, defined in 'PCI Firmware Specification Revision 3.1' 
section 4.6.7.( DSM for Naming a PCI or PCI Express Device Under
Operating Systems) to sysfs. So we need to compile pci-labe.c if either
of CONFIG_DMI or CONFIG_ACPI is set. When ACPI _DSM is available it
takes priority.

With regards,
Narendra K 

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
@ 2011-01-13 16:46       ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-13 16:46 UTC (permalink / raw)
  To: lenb
  Cc: jbarnes, linux-kernel, linux-next, sfr, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

On Thu, Jan 13, 2011 at 08:53:55AM +0530, Len Brown wrote:
> 
> > > drivers/built-in.o: In function `dsm_label_utf16s_to_utf8s':
> > > /usr/src/Linux-Next/linux-next/drivers/pci/pci-label.c:195: undefined reference to `utf16s_to_utf8s'
> > > make: *** [.tmp_vmlinux1] Error 1
> > > 
> > > The drivers/pci/pci-label.c is compiled as part of vmlinux as defined by
> > > the makefile drivers/pci/Makefile. 
> > > 
> > > #
> > > # ACPI Related PCI FW Functions
> > > # ACPI _DSM provided firmware instance and string name
> > > #
> > > obj-$(CONFIG_ACPI)    += pci-acpi.o pci-label.o
> > > 
> > > # SMBIOS provided firmware instance and labels
> > > obj-$(CONFIG_DMI)    += pci-label.o
> > > 
> > > This could be prevented by one of the following methods -
> > > 
> > > * forcing CONFIG_NLS=y if CONFIG_PCI=y 
> > > * move `utf16s_to_utf8s' out of nls_base.c to a new file to be always
> > > built into vmlinux
> > > 
> > > Please correct me if i missed something here and let me know what would be the right
> > > way to fix this build failure.
> > 
> > So there's no other ACPI code that depends on this function?  I'd hate
> > to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
> > case the select or depend should be there), I guess it should be pulled
> > into a common file that will always be included.
> 
> No, nothing in the ACPI code uses utf16s_to_utf8s.

Len,

Thanks for the information.

> 
> I don't know anything about NLS, but it appears to be
> something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
> use to to support native languages.
> 
> BTW. I don't understand why pci-label.o appears twice above.
> It used to be just the 2nd one, that depends on CONFIG_DMI.
> 

Support has been added to export ACPI _DSM provided firmware instance
number and string, defined in 'PCI Firmware Specification Revision 3.1' 
section 4.6.7.( DSM for Naming a PCI or PCI Express Device Under
Operating Systems) to sysfs. So we need to compile pci-labe.c if either
of CONFIG_DMI or CONFIG_ACPI is set. When ACPI _DSM is available it
takes priority.

With regards,
Narendra K 

^ permalink raw reply	[flat|nested] 31+ messages in thread

* [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
  2011-01-13 16:03         ` Narendra_K
@ 2011-01-14 15:22           ` Narendra_K
  -1 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-14 15:22 UTC (permalink / raw)
  To: jbarnes
  Cc: lenb, linux-kernel, linux-next, sfr, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Thu, Jan 13, 2011 at 09:33:56PM +0530, K, Narendra wrote:
> On Thu, Jan 13, 2011 at 09:25:56PM +0530, Jesse Barnes wrote:
> > On Wed, 12 Jan 2011 22:23:55 -0500 (EST)
> > Len Brown <lenb@kernel.org> wrote:
> > > > So there's no other ACPI code that depends on this function?  I'd hate
> > > > to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
> > > > case the select or depend should be there), I guess it should be pulled
> > > > into a common file that will always be included.
> > > 
> > > No, nothing in the ACPI code uses utf16s_to_utf8s.
> > > 
> > > I don't know anything about NLS, but it appears to be
> > > something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
> > > use to to support native languages.
> > > 
> > > BTW. I don't understand why pci-label.o appears twice above.
> > > It used to be just the 2nd one, that depends on CONFIG_DMI.
> > 
> > Ok, I'll drop this patch for now then since I haven't seen a fix yet
> > and need to get Linus the rest of the changes.
> 
> Jesse,
> 
> I just compile tested a fix on the following lines without any failure.
> If it is acceptable, i will send a patch in half an hour. It builds
> 

Hello,

This patch addresses the build failure described in this thread by
compiling fs/nls/nls_base.c always into vmlinux, thus making the base
nls functions available always.

Please consider this patch for inclusion if there are no concerns with
this approach.

From: Narendra K <narendra_k@dell.com>
Subject: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig

This patch fixes the following build breakage introduced by the patch
PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
(previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).

http://marc.info/?l=linux-pci&m=129313294112736&w=1

drivers/built-in.o: In function `T.647':
pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'

This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
into vmlinux.

This is fixed by making fs/nls/nls_base.c always compile as part of
vmlinux thus making the base nls functions available always.

Signed-off-by: Narendra K <narendra_k@dell.com>
---
 fs/Makefile     |    2 +-
 fs/nls/Makefile |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/Makefile b/fs/Makefile
index a7f7cef..1e78b9b 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
 obj-$(CONFIG_EXPORTFS)		+= exportfs/
 obj-$(CONFIG_NFSD)		+= nfsd/
 obj-$(CONFIG_LOCKD)		+= lockd/
-obj-$(CONFIG_NLS)		+= nls/
+obj-y				+= nls/
 obj-$(CONFIG_SYSV_FS)		+= sysv/
 obj-$(CONFIG_CIFS)		+= cifs/
 obj-$(CONFIG_NCP_FS)		+= ncpfs/
diff --git a/fs/nls/Makefile b/fs/nls/Makefile
index f499dd7..c172fbb 100644
--- a/fs/nls/Makefile
+++ b/fs/nls/Makefile
@@ -2,7 +2,7 @@
 # Makefile for native language support
 #
 
-obj-$(CONFIG_NLS)		+= nls_base.o
+obj-y				+= nls_base.o
 
 obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
 obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o
-- 
1.7.3.1

With regards,
Narendra K

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
@ 2011-01-14 15:22           ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-14 15:22 UTC (permalink / raw)
  To: jbarnes
  Cc: lenb, linux-kernel, linux-next, sfr, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Thu, Jan 13, 2011 at 09:33:56PM +0530, K, Narendra wrote:
> On Thu, Jan 13, 2011 at 09:25:56PM +0530, Jesse Barnes wrote:
> > On Wed, 12 Jan 2011 22:23:55 -0500 (EST)
> > Len Brown <lenb@kernel.org> wrote:
> > > > So there's no other ACPI code that depends on this function?  I'd hate
> > > > to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
> > > > case the select or depend should be there), I guess it should be pulled
> > > > into a common file that will always be included.
> > > 
> > > No, nothing in the ACPI code uses utf16s_to_utf8s.
> > > 
> > > I don't know anything about NLS, but it appears to be
> > > something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
> > > use to to support native languages.
> > > 
> > > BTW. I don't understand why pci-label.o appears twice above.
> > > It used to be just the 2nd one, that depends on CONFIG_DMI.
> > 
> > Ok, I'll drop this patch for now then since I haven't seen a fix yet
> > and need to get Linus the rest of the changes.
> 
> Jesse,
> 
> I just compile tested a fix on the following lines without any failure.
> If it is acceptable, i will send a patch in half an hour. It builds
> 

Hello,

This patch addresses the build failure described in this thread by
compiling fs/nls/nls_base.c always into vmlinux, thus making the base
nls functions available always.

Please consider this patch for inclusion if there are no concerns with
this approach.

From: Narendra K <narendra_k@dell.com>
Subject: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig

This patch fixes the following build breakage introduced by the patch
PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
(previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).

http://marc.info/?l=linux-pci&m=129313294112736&w=1

drivers/built-in.o: In function `T.647':
pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'

This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
into vmlinux.

This is fixed by making fs/nls/nls_base.c always compile as part of
vmlinux thus making the base nls functions available always.

Signed-off-by: Narendra K <narendra_k@dell.com>
---
 fs/Makefile     |    2 +-
 fs/nls/Makefile |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/fs/Makefile b/fs/Makefile
index a7f7cef..1e78b9b 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
 obj-$(CONFIG_EXPORTFS)		+= exportfs/
 obj-$(CONFIG_NFSD)		+= nfsd/
 obj-$(CONFIG_LOCKD)		+= lockd/
-obj-$(CONFIG_NLS)		+= nls/
+obj-y				+= nls/
 obj-$(CONFIG_SYSV_FS)		+= sysv/
 obj-$(CONFIG_CIFS)		+= cifs/
 obj-$(CONFIG_NCP_FS)		+= ncpfs/
diff --git a/fs/nls/Makefile b/fs/nls/Makefile
index f499dd7..c172fbb 100644
--- a/fs/nls/Makefile
+++ b/fs/nls/Makefile
@@ -2,7 +2,7 @@
 # Makefile for native language support
 #
 
-obj-$(CONFIG_NLS)		+= nls_base.o
+obj-y				+= nls_base.o
 
 obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
 obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o
-- 
1.7.3.1

With regards,
Narendra K

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
  2011-01-14 15:22           ` Narendra_K
  (?)
@ 2011-01-14 15:29           ` Sedat Dilek
  2011-01-14 16:06               ` Narendra_K
  -1 siblings, 1 reply; 31+ messages in thread
From: Sedat Dilek @ 2011-01-14 15:29 UTC (permalink / raw)
  To: Narendra_K
  Cc: jbarnes, lenb, linux-kernel, linux-next, sfr, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

On Fri, Jan 14, 2011 at 4:22 PM,  <Narendra_K@dell.com> wrote:
> On Thu, Jan 13, 2011 at 09:33:56PM +0530, K, Narendra wrote:
>> On Thu, Jan 13, 2011 at 09:25:56PM +0530, Jesse Barnes wrote:
>> > On Wed, 12 Jan 2011 22:23:55 -0500 (EST)
>> > Len Brown <lenb@kernel.org> wrote:
>> > > > So there's no other ACPI code that depends on this function?  I'd hate
>> > > > to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
>> > > > case the select or depend should be there), I guess it should be pulled
>> > > > into a common file that will always be included.
>> > >
>> > > No, nothing in the ACPI code uses utf16s_to_utf8s.
>> > >
>> > > I don't know anything about NLS, but it appears to be
>> > > something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
>> > > use to to support native languages.
>> > >
>> > > BTW. I don't understand why pci-label.o appears twice above.
>> > > It used to be just the 2nd one, that depends on CONFIG_DMI.
>> >
>> > Ok, I'll drop this patch for now then since I haven't seen a fix yet
>> > and need to get Linus the rest of the changes.
>>
>> Jesse,
>>
>> I just compile tested a fix on the following lines without any failure.
>> If it is acceptable, i will send a patch in half an hour. It builds
>>
>
> Hello,
>
> This patch addresses the build failure described in this thread by
> compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> nls functions available always.
>
> Please consider this patch for inclusion if there are no concerns with
> this approach.
>

So NLS is built always?
You thought of embedded devices like router platforms which want to
reduce their kernel (size) by not building NLS?

- Sedat -

^ permalink raw reply	[flat|nested] 31+ messages in thread

* RE: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
  2011-01-14 15:29           ` Sedat Dilek
@ 2011-01-14 16:06               ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-14 16:06 UTC (permalink / raw)
  To: sedat.dilek
  Cc: jbarnes, lenb, linux-kernel, linux-next, sfr, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="utf-8", Size: 2499 bytes --]

> Subject: Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by
> allmodconfig
> 
> On Fri, Jan 14, 2011 at 4:22 PM,  <Narendra_K@dell.com> wrote:
> > On Thu, Jan 13, 2011 at 09:33:56PM +0530, K, Narendra wrote:
> >> On Thu, Jan 13, 2011 at 09:25:56PM +0530, Jesse Barnes wrote:
> >> > On Wed, 12 Jan 2011 22:23:55 -0500 (EST)
> >> > Len Brown <lenb@kernel.org> wrote:
> >> > > > So there's no other ACPI code that depends on this function?
>  I'd hate
> >> > > > to make PCI depend on NLS, so assuming ACPI doesn't need it
> (in which
> >> > > > case the select or depend should be there), I guess it should
> be pulled
> >> > > > into a common file that will always be included.
> >> > >
> >> > > No, nothing in the ACPI code uses utf16s_to_utf8s.
> >> > >
> >> > > I don't know anything about NLS, but it appears to be
> >> > > something that file systems (befs, cifs, fat, hfs, isofs, jfs,
> etc)
> >> > > use to to support native languages.
> >> > >
> >> > > BTW. I don't understand why pci-label.o appears twice above.
> >> > > It used to be just the 2nd one, that depends on CONFIG_DMI.
> >> >
> >> > Ok, I'll drop this patch for now then since I haven't seen a fix
> yet
> >> > and need to get Linus the rest of the changes.
> >>
> >> Jesse,
> >>
> >> I just compile tested a fix on the following lines without any
> failure.
> >> If it is acceptable, i will send a patch in half an hour. It builds
> >>
> >
> > Hello,
> >
> > This patch addresses the build failure described in this thread by
> > compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> > nls functions available always.
> >
> > Please consider this patch for inclusion if there are no concerns
> with
> > this approach.
> >
> 
> So NLS is built always?
> You thought of embedded devices like router platforms which want to
> reduce their kernel (size) by not building NLS?

Only nls_base.c is built always and not the other files under fs/nls/ dir. I considered moving 'utf16s_to_utf8s' to a new file nls_common.c, but 'utf16s_to_utf8s' requires 'utf32_to_utf8' also. I suppose nls_base.c has only the minimum required functions and moving out two functions out of it might not be the right approach. Sorry if I am missing something here.

Please let me know if this can be addressed in an alternative way.

With regards,
Narendra K



ÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þG«éÿŠ{ayº\x1dʇڙë,j\a­¢f£¢·hšïêÿ‘êçz_è®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?™¨è­Ú&£ø§~á¶iO•æ¬z·švØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?–I¥

^ permalink raw reply	[flat|nested] 31+ messages in thread

* RE: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
@ 2011-01-14 16:06               ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-14 16:06 UTC (permalink / raw)
  To: sedat.dilek
  Cc: jbarnes, lenb, linux-kernel, linux-next, sfr, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

> Subject: Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by
> allmodconfig
> 
> On Fri, Jan 14, 2011 at 4:22 PM,  <Narendra_K@dell.com> wrote:
> > On Thu, Jan 13, 2011 at 09:33:56PM +0530, K, Narendra wrote:
> >> On Thu, Jan 13, 2011 at 09:25:56PM +0530, Jesse Barnes wrote:
> >> > On Wed, 12 Jan 2011 22:23:55 -0500 (EST)
> >> > Len Brown <lenb@kernel.org> wrote:
> >> > > > So there's no other ACPI code that depends on this function?
>  I'd hate
> >> > > > to make PCI depend on NLS, so assuming ACPI doesn't need it
> (in which
> >> > > > case the select or depend should be there), I guess it should
> be pulled
> >> > > > into a common file that will always be included.
> >> > >
> >> > > No, nothing in the ACPI code uses utf16s_to_utf8s.
> >> > >
> >> > > I don't know anything about NLS, but it appears to be
> >> > > something that file systems (befs, cifs, fat, hfs, isofs, jfs,
> etc)
> >> > > use to to support native languages.
> >> > >
> >> > > BTW. I don't understand why pci-label.o appears twice above.
> >> > > It used to be just the 2nd one, that depends on CONFIG_DMI.
> >> >
> >> > Ok, I'll drop this patch for now then since I haven't seen a fix
> yet
> >> > and need to get Linus the rest of the changes.
> >>
> >> Jesse,
> >>
> >> I just compile tested a fix on the following lines without any
> failure.
> >> If it is acceptable, i will send a patch in half an hour. It builds
> >>
> >
> > Hello,
> >
> > This patch addresses the build failure described in this thread by
> > compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> > nls functions available always.
> >
> > Please consider this patch for inclusion if there are no concerns
> with
> > this approach.
> >
> 
> So NLS is built always?
> You thought of embedded devices like router platforms which want to
> reduce their kernel (size) by not building NLS?

Only nls_base.c is built always and not the other files under fs/nls/ dir. I considered moving 'utf16s_to_utf8s' to a new file nls_common.c, but 'utf16s_to_utf8s' requires 'utf32_to_utf8' also. I suppose nls_base.c has only the minimum required functions and moving out two functions out of it might not be the right approach. Sorry if I am missing something here.

Please let me know if this can be addressed in an alternative way.

With regards,
Narendra K




^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
  2011-01-13 16:03         ` Narendra_K
@ 2011-01-14 17:14           ` Jesse Barnes
  -1 siblings, 0 replies; 31+ messages in thread
From: Jesse Barnes @ 2011-01-14 17:14 UTC (permalink / raw)
  To: Narendra_K
  Cc: lenb, linux-kernel, linux-next, sfr, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Thu, 13 Jan 2011 08:03:56 -0800
<Narendra_K@Dell.com> wrote:

> On Thu, Jan 13, 2011 at 09:25:56PM +0530, Jesse Barnes wrote:
> > On Wed, 12 Jan 2011 22:23:55 -0500 (EST)
> > Len Brown <lenb@kernel.org> wrote:
> > > > So there's no other ACPI code that depends on this function?  I'd hate
> > > > to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
> > > > case the select or depend should be there), I guess it should be pulled
> > > > into a common file that will always be included.
> > > 
> > > No, nothing in the ACPI code uses utf16s_to_utf8s.
> > > 
> > > I don't know anything about NLS, but it appears to be
> > > something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
> > > use to to support native languages.
> > > 
> > > BTW. I don't understand why pci-label.o appears twice above.
> > > It used to be just the 2nd one, that depends on CONFIG_DMI.
> > 
> > Ok, I'll drop this patch for now then since I haven't seen a fix yet
> > and need to get Linus the rest of the changes.
> 
> Jesse,
> 
> I just compile tested a fix on the following lines without any failure.
> If it is acceptable, i will send a patch in half an hour. It builds
> 
> diff --git a/fs/Makefile b/fs/Makefile
> index db71a5b..2a39275 100644
> --- a/fs/Makefile
> +++ b/fs/Makefile
> @@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
>  obj-$(CONFIG_EXPORTFS)		+= exportfs/
>  obj-$(CONFIG_NFSD)		+= nfsd/
>  obj-$(CONFIG_LOCKD)		+= lockd/
> -obj-$(CONFIG_NLS)		+= nls/
> +obj-y				+= nls/
>  obj-$(CONFIG_SYSV_FS)		+= sysv/
>  obj-$(CONFIG_CIFS)		+= cifs/
>  obj-$(CONFIG_NCP_FS)		+= ncpfs/
> diff --git a/fs/nls/Makefile b/fs/nls/Makefile
> index f499dd7..c172fbb 100644
> --- a/fs/nls/Makefile
> +++ b/fs/nls/Makefile
> @@ -2,7 +2,7 @@
>  # Makefile for native language support
>  #
>  
> -obj-$(CONFIG_NLS)		+= nls_base.o
> +obj-y				+= nls_base.o
>  
>  obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
>  obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o

nls_base.c is pretty small, but I don't want to make it unconditional.
If you don't want to split out the necessary functions into lib/ or
something, then it might be best to make the new code in
pci-label.c conditional on a new config option that describes the
feature, points at the documentation, and either selects or depends on
nls support (documenting it in the help text either way).

Thanks,
-- 
Jesse Barnes, Intel Open Source Technology Center

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure
@ 2011-01-14 17:14           ` Jesse Barnes
  0 siblings, 0 replies; 31+ messages in thread
From: Jesse Barnes @ 2011-01-14 17:14 UTC (permalink / raw)
  To: Narendra_K
  Cc: lenb, linux-kernel, linux-next, sfr, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Thu, 13 Jan 2011 08:03:56 -0800
<Narendra_K@Dell.com> wrote:

> On Thu, Jan 13, 2011 at 09:25:56PM +0530, Jesse Barnes wrote:
> > On Wed, 12 Jan 2011 22:23:55 -0500 (EST)
> > Len Brown <lenb@kernel.org> wrote:
> > > > So there's no other ACPI code that depends on this function?  I'd hate
> > > > to make PCI depend on NLS, so assuming ACPI doesn't need it (in which
> > > > case the select or depend should be there), I guess it should be pulled
> > > > into a common file that will always be included.
> > > 
> > > No, nothing in the ACPI code uses utf16s_to_utf8s.
> > > 
> > > I don't know anything about NLS, but it appears to be
> > > something that file systems (befs, cifs, fat, hfs, isofs, jfs, etc)
> > > use to to support native languages.
> > > 
> > > BTW. I don't understand why pci-label.o appears twice above.
> > > It used to be just the 2nd one, that depends on CONFIG_DMI.
> > 
> > Ok, I'll drop this patch for now then since I haven't seen a fix yet
> > and need to get Linus the rest of the changes.
> 
> Jesse,
> 
> I just compile tested a fix on the following lines without any failure.
> If it is acceptable, i will send a patch in half an hour. It builds
> 
> diff --git a/fs/Makefile b/fs/Makefile
> index db71a5b..2a39275 100644
> --- a/fs/Makefile
> +++ b/fs/Makefile
> @@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
>  obj-$(CONFIG_EXPORTFS)		+= exportfs/
>  obj-$(CONFIG_NFSD)		+= nfsd/
>  obj-$(CONFIG_LOCKD)		+= lockd/
> -obj-$(CONFIG_NLS)		+= nls/
> +obj-y				+= nls/
>  obj-$(CONFIG_SYSV_FS)		+= sysv/
>  obj-$(CONFIG_CIFS)		+= cifs/
>  obj-$(CONFIG_NCP_FS)		+= ncpfs/
> diff --git a/fs/nls/Makefile b/fs/nls/Makefile
> index f499dd7..c172fbb 100644
> --- a/fs/nls/Makefile
> +++ b/fs/nls/Makefile
> @@ -2,7 +2,7 @@
>  # Makefile for native language support
>  #
>  
> -obj-$(CONFIG_NLS)		+= nls_base.o
> +obj-y				+= nls_base.o
>  
>  obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
>  obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o

nls_base.c is pretty small, but I don't want to make it unconditional.
If you don't want to split out the necessary functions into lib/ or
something, then it might be best to make the new code in
pci-label.c conditional on a new config option that describes the
feature, points at the documentation, and either selects or depends on
nls support (documenting it in the help text either way).

Thanks,
-- 
Jesse Barnes, Intel Open Source Technology Center

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
  2011-01-14 15:22           ` Narendra_K
@ 2011-01-14 21:09             ` Stephen Rothwell
  -1 siblings, 0 replies; 31+ messages in thread
From: Stephen Rothwell @ 2011-01-14 21:09 UTC (permalink / raw)
  To: Narendra_K
  Cc: jbarnes, lenb, linux-kernel, linux-next, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

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

Hi Narendra,

On Fri, 14 Jan 2011 20:52:42 +0530 <Narendra_K@Dell.com> wrote:
>
> This patch addresses the build failure described in this thread by
> compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> nls functions available always.

Even on platforms that don't support ACPI or DMI ...

> From: Narendra K <narendra_k@dell.com>
> Subject: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> 
> This patch fixes the following build breakage introduced by the patch
> PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
> (previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).
> 
> http://marc.info/?l=linux-pci&m=129313294112736&w=1
> 
> drivers/built-in.o: In function `T.647':
> pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'
> 
> This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
> 'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
> into vmlinux.
> 
> This is fixed by making fs/nls/nls_base.c always compile as part of
> vmlinux thus making the base nls functions available always.
> +++ b/fs/nls/Makefile
> @@ -2,7 +2,7 @@
>  # Makefile for native language support
>  #
>  
> -obj-$(CONFIG_NLS)		+= nls_base.o
> +obj-y				+= nls_base.o

You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
DMI and NLS?

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
@ 2011-01-14 21:09             ` Stephen Rothwell
  0 siblings, 0 replies; 31+ messages in thread
From: Stephen Rothwell @ 2011-01-14 21:09 UTC (permalink / raw)
  To: Narendra_K
  Cc: jbarnes, lenb, linux-kernel, linux-next, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

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

Hi Narendra,

On Fri, 14 Jan 2011 20:52:42 +0530 <Narendra_K@Dell.com> wrote:
>
> This patch addresses the build failure described in this thread by
> compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> nls functions available always.

Even on platforms that don't support ACPI or DMI ...

> From: Narendra K <narendra_k@dell.com>
> Subject: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> 
> This patch fixes the following build breakage introduced by the patch
> PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
> (previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).
> 
> http://marc.info/?l=linux-pci&m=129313294112736&w=1
> 
> drivers/built-in.o: In function `T.647':
> pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'
> 
> This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
> 'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
> into vmlinux.
> 
> This is fixed by making fs/nls/nls_base.c always compile as part of
> vmlinux thus making the base nls functions available always.
> +++ b/fs/nls/Makefile
> @@ -2,7 +2,7 @@
>  # Makefile for native language support
>  #
>  
> -obj-$(CONFIG_NLS)		+= nls_base.o
> +obj-y				+= nls_base.o

You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
DMI and NLS?

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

[-- Attachment #2: Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
  2011-01-14 21:09             ` Stephen Rothwell
@ 2011-01-17 19:28               ` Narendra_K
  -1 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-17 19:28 UTC (permalink / raw)
  To: sfr
  Cc: jbarnes, lenb, linux-kernel, linux-next, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

On Sat, Jan 15, 2011 at 02:39:49AM +0530, Stephen Rothwell wrote:
> Hi Narendra,
> 
> On Fri, 14 Jan 2011 20:52:42 +0530 <Narendra_K@Dell.com> wrote:
> >
> > This patch addresses the build failure described in this thread by
> > compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> > nls functions available always.
> 
> Even on platforms that don't support ACPI or DMI ...
> 
> > From: Narendra K <narendra_k@dell.com>
> > Subject: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> > 
> > This patch fixes the following build breakage introduced by the patch
> > PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
> > (previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).
> > 
> > http://marc.info/?l=linux-pci&m=129313294112736&w=1
> > 
> > drivers/built-in.o: In function `T.647':
> > pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'
> > 
> > This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
> > 'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
> > into vmlinux.
> > 
> > This is fixed by making fs/nls/nls_base.c always compile as part of
> > vmlinux thus making the base nls functions available always.
> > +++ b/fs/nls/Makefile
> > @@ -2,7 +2,7 @@
> >  # Makefile for native language support
> >  #
> >  
> > -obj-$(CONFIG_NLS)		+= nls_base.o
> > +obj-y				+= nls_base.o
> 
> You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> DMI and NLS?

Hi Stephen,

Thank you for the suggestions. 

I agree with your suggestion that we should compile nls_base.o
conditionally, only when ACPI || DMI || NLS. I have introduced a bew
config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.

V1 -> V2:

1. Conditionally compile fs/nls/nls_base.c by introducing a new config
option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
Behavior of the rest of the files under fs/nls is not changed.

From: Narendra K <narendra_k@dell.com>
Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig

This patch fixes the following build breakage introduced by the patch
PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
(previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).

http://marc.info/?l=linux-pci&m=129313294112736&w=1

drivers/built-in.o: In function `T.647':
pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'

This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
into vmlinux.

This is fixed by making fs/nls/nls_base.c compile conditionally into
vmlinux by introducing a new config option CONFIG_NLS_BASE which is
selected by (ACPI || DMI || NLS). This makes

Signed-off-by: Narendra K <narendra_k@dell.com>
---
 fs/Makefile     |    2 +-
 fs/nls/Kconfig  |   14 ++++++++++++++
 fs/nls/Makefile |    2 +-
 3 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/fs/Makefile b/fs/Makefile
index a7f7cef..1e78b9b 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
 obj-$(CONFIG_EXPORTFS)		+= exportfs/
 obj-$(CONFIG_NFSD)		+= nfsd/
 obj-$(CONFIG_LOCKD)		+= lockd/
-obj-$(CONFIG_NLS)		+= nls/
+obj-y				+= nls/
 obj-$(CONFIG_SYSV_FS)		+= sysv/
 obj-$(CONFIG_CIFS)		+= cifs/
 obj-$(CONFIG_NCP_FS)		+= ncpfs/
diff --git a/fs/nls/Kconfig b/fs/nls/Kconfig
index a39edc4..2fb92e5 100644
--- a/fs/nls/Kconfig
+++ b/fs/nls/Kconfig
@@ -4,6 +4,7 @@
 
 menuconfig NLS
 	tristate "Native language support"
+	select NLS_BASE
 	---help---
 	  The base Native Language Support. A number of filesystems
 	  depend on it (e.g. FAT, JOLIET, NT, BEOS filesystems), as well
@@ -17,6 +18,19 @@ menuconfig NLS
 
 if NLS
 
+config NLS_BASE
+	bool "Base NLS functions"
+	depends on ACPI || DMI
+	default y
+	---help---
+	  The base NLS support functions which handle unicode traslations.
+
+	  If unsure, say Y.
+
+	  This config option is selected by ACPI && DMI && NLS as the
+	  functions defined here are needed in vmlinux and if built as
+	  module cause build issues.
+
 config NLS_DEFAULT
 	string "Default NLS Option"
 	default "iso8859-1"
diff --git a/fs/nls/Makefile b/fs/nls/Makefile
index f499dd7..dde741f 100644
--- a/fs/nls/Makefile
+++ b/fs/nls/Makefile
@@ -2,7 +2,7 @@
 # Makefile for native language support
 #
 
-obj-$(CONFIG_NLS)		+= nls_base.o
+obj-$(CONFIG_NLS_BASE)		+= nls_base.o
 
 obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
 obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o
-- 
1.7.3.1

With regards,
Narendra K

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
@ 2011-01-17 19:28               ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-17 19:28 UTC (permalink / raw)
  To: sfr
  Cc: jbarnes, lenb, linux-kernel, linux-next, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

On Sat, Jan 15, 2011 at 02:39:49AM +0530, Stephen Rothwell wrote:
> Hi Narendra,
> 
> On Fri, 14 Jan 2011 20:52:42 +0530 <Narendra_K@Dell.com> wrote:
> >
> > This patch addresses the build failure described in this thread by
> > compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> > nls functions available always.
> 
> Even on platforms that don't support ACPI or DMI ...
> 
> > From: Narendra K <narendra_k@dell.com>
> > Subject: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> > 
> > This patch fixes the following build breakage introduced by the patch
> > PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
> > (previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).
> > 
> > http://marc.info/?l=linux-pci&m=129313294112736&w=1
> > 
> > drivers/built-in.o: In function `T.647':
> > pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'
> > 
> > This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
> > 'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
> > into vmlinux.
> > 
> > This is fixed by making fs/nls/nls_base.c always compile as part of
> > vmlinux thus making the base nls functions available always.
> > +++ b/fs/nls/Makefile
> > @@ -2,7 +2,7 @@
> >  # Makefile for native language support
> >  #
> >  
> > -obj-$(CONFIG_NLS)		+= nls_base.o
> > +obj-y				+= nls_base.o
> 
> You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> DMI and NLS?

Hi Stephen,

Thank you for the suggestions. 

I agree with your suggestion that we should compile nls_base.o
conditionally, only when ACPI || DMI || NLS. I have introduced a bew
config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.

V1 -> V2:

1. Conditionally compile fs/nls/nls_base.c by introducing a new config
option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
Behavior of the rest of the files under fs/nls is not changed.

From: Narendra K <narendra_k@dell.com>
Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig

This patch fixes the following build breakage introduced by the patch
PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
(previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).

http://marc.info/?l=linux-pci&m=129313294112736&w=1

drivers/built-in.o: In function `T.647':
pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'

This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
into vmlinux.

This is fixed by making fs/nls/nls_base.c compile conditionally into
vmlinux by introducing a new config option CONFIG_NLS_BASE which is
selected by (ACPI || DMI || NLS). This makes

Signed-off-by: Narendra K <narendra_k@dell.com>
---
 fs/Makefile     |    2 +-
 fs/nls/Kconfig  |   14 ++++++++++++++
 fs/nls/Makefile |    2 +-
 3 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/fs/Makefile b/fs/Makefile
index a7f7cef..1e78b9b 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
 obj-$(CONFIG_EXPORTFS)		+= exportfs/
 obj-$(CONFIG_NFSD)		+= nfsd/
 obj-$(CONFIG_LOCKD)		+= lockd/
-obj-$(CONFIG_NLS)		+= nls/
+obj-y				+= nls/
 obj-$(CONFIG_SYSV_FS)		+= sysv/
 obj-$(CONFIG_CIFS)		+= cifs/
 obj-$(CONFIG_NCP_FS)		+= ncpfs/
diff --git a/fs/nls/Kconfig b/fs/nls/Kconfig
index a39edc4..2fb92e5 100644
--- a/fs/nls/Kconfig
+++ b/fs/nls/Kconfig
@@ -4,6 +4,7 @@
 
 menuconfig NLS
 	tristate "Native language support"
+	select NLS_BASE
 	---help---
 	  The base Native Language Support. A number of filesystems
 	  depend on it (e.g. FAT, JOLIET, NT, BEOS filesystems), as well
@@ -17,6 +18,19 @@ menuconfig NLS
 
 if NLS
 
+config NLS_BASE
+	bool "Base NLS functions"
+	depends on ACPI || DMI
+	default y
+	---help---
+	  The base NLS support functions which handle unicode traslations.
+
+	  If unsure, say Y.
+
+	  This config option is selected by ACPI && DMI && NLS as the
+	  functions defined here are needed in vmlinux and if built as
+	  module cause build issues.
+
 config NLS_DEFAULT
 	string "Default NLS Option"
 	default "iso8859-1"
diff --git a/fs/nls/Makefile b/fs/nls/Makefile
index f499dd7..dde741f 100644
--- a/fs/nls/Makefile
+++ b/fs/nls/Makefile
@@ -2,7 +2,7 @@
 # Makefile for native language support
 #
 
-obj-$(CONFIG_NLS)		+= nls_base.o
+obj-$(CONFIG_NLS_BASE)		+= nls_base.o
 
 obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
 obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o
-- 
1.7.3.1

With regards,
Narendra K

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
  2011-01-17 19:28               ` Narendra_K
@ 2011-01-20 18:41                 ` Narendra_K
  -1 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-20 18:41 UTC (permalink / raw)
  To: sfr
  Cc: jbarnes, lenb, linux-kernel, linux-next, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

On Tue, Jan 18, 2011 at 12:58:48AM +0530, K, Narendra wrote:
> On Sat, Jan 15, 2011 at 02:39:49AM +0530, Stephen Rothwell wrote:
> > Hi Narendra,
> > 
> > On Fri, 14 Jan 2011 20:52:42 +0530 <Narendra_K@Dell.com> wrote:
> > >
> > > This patch addresses the build failure described in this thread by
> > > compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> > > nls functions available always.
> > 
> > Even on platforms that don't support ACPI or DMI ...
> > 
> > You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> > CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> > DMI and NLS?
> 
> Hi Stephen,
> 
> Thank you for the suggestions. 
> 
> I agree with your suggestion that we should compile nls_base.o
> conditionally, only when ACPI || DMI || NLS. I have introduced a bew
> config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.
> 
> V1 -> V2:
> 
> 1. Conditionally compile fs/nls/nls_base.c by introducing a new config
> option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
> Behavior of the rest of the files under fs/nls is not changed.
> 
> From: Narendra K <narendra_k@dell.com>
> Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig

Hi,

Please let me know if there are any concerns with Version 2 of the patch.
If it looks good please consider it for inclusion.

With regards,
Narendra K

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
@ 2011-01-20 18:41                 ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-20 18:41 UTC (permalink / raw)
  To: sfr
  Cc: jbarnes, lenb, linux-kernel, linux-next, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

On Tue, Jan 18, 2011 at 12:58:48AM +0530, K, Narendra wrote:
> On Sat, Jan 15, 2011 at 02:39:49AM +0530, Stephen Rothwell wrote:
> > Hi Narendra,
> > 
> > On Fri, 14 Jan 2011 20:52:42 +0530 <Narendra_K@Dell.com> wrote:
> > >
> > > This patch addresses the build failure described in this thread by
> > > compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> > > nls functions available always.
> > 
> > Even on platforms that don't support ACPI or DMI ...
> > 
> > You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> > CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> > DMI and NLS?
> 
> Hi Stephen,
> 
> Thank you for the suggestions. 
> 
> I agree with your suggestion that we should compile nls_base.o
> conditionally, only when ACPI || DMI || NLS. I have introduced a bew
> config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.
> 
> V1 -> V2:
> 
> 1. Conditionally compile fs/nls/nls_base.c by introducing a new config
> option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
> Behavior of the rest of the files under fs/nls is not changed.
> 
> From: Narendra K <narendra_k@dell.com>
> Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig

Hi,

Please let me know if there are any concerns with Version 2 of the patch.
If it looks good please consider it for inclusion.

With regards,
Narendra K

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
  2011-01-20 18:41                 ` Narendra_K
@ 2011-01-28 15:30                   ` Narendra_K
  -1 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-28 15:30 UTC (permalink / raw)
  To: sfr
  Cc: jbarnes, lenb, linux-kernel, linux-next, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

On Fri, Jan 21, 2011 at 12:11:50AM +0530, K, Narendra wrote:
> On Tue, Jan 18, 2011 at 12:58:48AM +0530, K, Narendra wrote:
> > On Sat, Jan 15, 2011 at 02:39:49AM +0530, Stephen Rothwell wrote:
> > > Hi Narendra,
> > > 
> > > On Fri, 14 Jan 2011 20:52:42 +0530 <Narendra_K@Dell.com> wrote:
> > > >
> > > > This patch addresses the build failure described in this thread by
> > > > compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> > > > nls functions available always.
> > > 
> > > Even on platforms that don't support ACPI or DMI ...
> > > 
> > > You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> > > CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> > > DMI and NLS?
> > 
> > Hi Stephen,
> > 
> > Thank you for the suggestions. 
> > 
> > I agree with your suggestion that we should compile nls_base.o
> > conditionally, only when ACPI || DMI || NLS. I have introduced a bew
> > config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.
> > 
> > V1 -> V2:
> > 
> > 1. Conditionally compile fs/nls/nls_base.c by introducing a new config
> > option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
> > Behavior of the rest of the files under fs/nls is not changed.
> > 
> > From: Narendra K <narendra_k@dell.com>
> > Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> 
> Hi,
> 
> Please let me know if there are any concerns with Version 2 of the patch.
> If it looks good please consider it for inclusion.

Hi Jesse,

Please let me know if there are any concerns with this patch. If it is
acceptable, please consider this for inclusion.

With regards,
Narendra K

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
@ 2011-01-28 15:30                   ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-01-28 15:30 UTC (permalink / raw)
  To: sfr
  Cc: jbarnes, lenb, linux-kernel, linux-next, Matt_Domsch,
	Charles_Rose, Surya_Prabhakar

On Fri, Jan 21, 2011 at 12:11:50AM +0530, K, Narendra wrote:
> On Tue, Jan 18, 2011 at 12:58:48AM +0530, K, Narendra wrote:
> > On Sat, Jan 15, 2011 at 02:39:49AM +0530, Stephen Rothwell wrote:
> > > Hi Narendra,
> > > 
> > > On Fri, 14 Jan 2011 20:52:42 +0530 <Narendra_K@Dell.com> wrote:
> > > >
> > > > This patch addresses the build failure described in this thread by
> > > > compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> > > > nls functions available always.
> > > 
> > > Even on platforms that don't support ACPI or DMI ...
> > > 
> > > You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> > > CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> > > DMI and NLS?
> > 
> > Hi Stephen,
> > 
> > Thank you for the suggestions. 
> > 
> > I agree with your suggestion that we should compile nls_base.o
> > conditionally, only when ACPI || DMI || NLS. I have introduced a bew
> > config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.
> > 
> > V1 -> V2:
> > 
> > 1. Conditionally compile fs/nls/nls_base.c by introducing a new config
> > option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
> > Behavior of the rest of the files under fs/nls is not changed.
> > 
> > From: Narendra K <narendra_k@dell.com>
> > Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> 
> Hi,
> 
> Please let me know if there are any concerns with Version 2 of the patch.
> If it looks good please consider it for inclusion.

Hi Jesse,

Please let me know if there are any concerns with this patch. If it is
acceptable, please consider this for inclusion.

With regards,
Narendra K

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
  2011-01-28 15:30                   ` Narendra_K
@ 2011-01-28 16:45                     ` Jesse Barnes
  -1 siblings, 0 replies; 31+ messages in thread
From: Jesse Barnes @ 2011-01-28 16:45 UTC (permalink / raw)
  To: Narendra_K
  Cc: sfr, lenb, linux-kernel, linux-next, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Fri, 28 Jan 2011 07:30:36 -0800
<Narendra_K@Dell.com> wrote:

> On Fri, Jan 21, 2011 at 12:11:50AM +0530, K, Narendra wrote:
> > On Tue, Jan 18, 2011 at 12:58:48AM +0530, K, Narendra wrote:
> > > On Sat, Jan 15, 2011 at 02:39:49AM +0530, Stephen Rothwell wrote:
> > > > Hi Narendra,
> > > > 
> > > > On Fri, 14 Jan 2011 20:52:42 +0530 <Narendra_K@Dell.com> wrote:
> > > > >
> > > > > This patch addresses the build failure described in this thread by
> > > > > compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> > > > > nls functions available always.
> > > > 
> > > > Even on platforms that don't support ACPI or DMI ...
> > > > 
> > > > You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> > > > CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> > > > DMI and NLS?
> > > 
> > > Hi Stephen,
> > > 
> > > Thank you for the suggestions. 
> > > 
> > > I agree with your suggestion that we should compile nls_base.o
> > > conditionally, only when ACPI || DMI || NLS. I have introduced a bew
> > > config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.
> > > 
> > > V1 -> V2:
> > > 
> > > 1. Conditionally compile fs/nls/nls_base.c by introducing a new config
> > > option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
> > > Behavior of the rest of the files under fs/nls is not changed.
> > > 
> > > From: Narendra K <narendra_k@dell.com>
> > > Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> > 
> > Hi,
> > 
> > Please let me know if there are any concerns with Version 2 of the patch.
> > If it looks good please consider it for inclusion.
> 
> Hi Jesse,
> 
> Please let me know if there are any concerns with this patch. If it is
> acceptable, please consider this for inclusion.

I think the fs stuff will have to get an ack from Al.  If he doesn't
like it, see my earlier mail for another suggestion.

-- 
Jesse Barnes, Intel Open Source Technology Center

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
@ 2011-01-28 16:45                     ` Jesse Barnes
  0 siblings, 0 replies; 31+ messages in thread
From: Jesse Barnes @ 2011-01-28 16:45 UTC (permalink / raw)
  To: Narendra_K
  Cc: sfr, lenb, linux-kernel, linux-next, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Fri, 28 Jan 2011 07:30:36 -0800
<Narendra_K@Dell.com> wrote:

> On Fri, Jan 21, 2011 at 12:11:50AM +0530, K, Narendra wrote:
> > On Tue, Jan 18, 2011 at 12:58:48AM +0530, K, Narendra wrote:
> > > On Sat, Jan 15, 2011 at 02:39:49AM +0530, Stephen Rothwell wrote:
> > > > Hi Narendra,
> > > > 
> > > > On Fri, 14 Jan 2011 20:52:42 +0530 <Narendra_K@Dell.com> wrote:
> > > > >
> > > > > This patch addresses the build failure described in this thread by
> > > > > compiling fs/nls/nls_base.c always into vmlinux, thus making the base
> > > > > nls functions available always.
> > > > 
> > > > Even on platforms that don't support ACPI or DMI ...
> > > > 
> > > > You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> > > > CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> > > > DMI and NLS?
> > > 
> > > Hi Stephen,
> > > 
> > > Thank you for the suggestions. 
> > > 
> > > I agree with your suggestion that we should compile nls_base.o
> > > conditionally, only when ACPI || DMI || NLS. I have introduced a bew
> > > config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.
> > > 
> > > V1 -> V2:
> > > 
> > > 1. Conditionally compile fs/nls/nls_base.c by introducing a new config
> > > option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
> > > Behavior of the rest of the files under fs/nls is not changed.
> > > 
> > > From: Narendra K <narendra_k@dell.com>
> > > Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> > 
> > Hi,
> > 
> > Please let me know if there are any concerns with Version 2 of the patch.
> > If it looks good please consider it for inclusion.
> 
> Hi Jesse,
> 
> Please let me know if there are any concerns with this patch. If it is
> acceptable, please consider this for inclusion.

I think the fs stuff will have to get an ack from Al.  If he doesn't
like it, see my earlier mail for another suggestion.

-- 
Jesse Barnes, Intel Open Source Technology Center

^ permalink raw reply	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
  2011-01-28 16:45                     ` Jesse Barnes
@ 2011-02-01 16:28                       ` Narendra_K
  -1 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-02-01 16:28 UTC (permalink / raw)
  To: jbarnes
  Cc: sfr, lenb, linux-kernel, linux-next, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Fri, Jan 28, 2011 at 10:15:18PM +0530, Jesse Barnes wrote:
> > > > > 
> > > > > Even on platforms that don't support ACPI or DMI ...
> > > > > 
> > > > > You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> > > > > CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> > > > > DMI and NLS?
> > > > 
> > > > Hi Stephen,
> > > > 
> > > > Thank you for the suggestions. 
> > > > 
> > > > I agree with your suggestion that we should compile nls_base.o
> > > > conditionally, only when ACPI || DMI || NLS. I have introduced a bew
> > > > config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.
> > > > 
> > > > V1 -> V2:
> > > > 
> > > > 1. Conditionally compile fs/nls/nls_base.c by introducing a new config
> > > > option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
> > > > Behavior of the rest of the files under fs/nls is not changed.
> > > > 
> > > > From: Narendra K <narendra_k@dell.com>
> > > > Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> > > 
> > > Hi,
> > > 
> > > Please let me know if there are any concerns with Version 2 of the patch.
> > > If it looks good please consider it for inclusion.
> > 
> > Hi Jesse,
> > 
> > Please let me know if there are any concerns with this patch. If it is
> > acceptable, please consider this for inclusion.
> 
> I think the fs stuff will have to get an ack from Al.  If he doesn't
> like it, see my earlier mail for another suggestion.

Hi Al,

Please let me know if there are any concerns with this patch. If not,
please ack this patch.

I have attached the patch here for your reference -

From: Narendra K <narendra_k@dell.com>
Subject: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig

This patch fixes the following build breakage introduced by the patch
PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
(previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).

http://marc.info/?l=linux-pci&m=129313294112736&w=1

drivers/built-in.o: In function `T.647':
pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'

This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
into vmlinux.

This is fixed by making fs/nls/nls_base.c compile conditionally into
vmlinux by introducing a new config option CONFIG_NLS_BASE which is
selected by (ACPI || DMI || NLS).

Signed-off-by: Narendra K <narendra_k@dell.com>
---
 fs/Makefile     |    2 +-
 fs/nls/Kconfig  |   14 ++++++++++++++
 fs/nls/Makefile |    2 +-
 3 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/fs/Makefile b/fs/Makefile
index a7f7cef..1e78b9b 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
 obj-$(CONFIG_EXPORTFS)		+= exportfs/
 obj-$(CONFIG_NFSD)		+= nfsd/
 obj-$(CONFIG_LOCKD)		+= lockd/
-obj-$(CONFIG_NLS)		+= nls/
+obj-y				+= nls/
 obj-$(CONFIG_SYSV_FS)		+= sysv/
 obj-$(CONFIG_CIFS)		+= cifs/
 obj-$(CONFIG_NCP_FS)		+= ncpfs/
diff --git a/fs/nls/Kconfig b/fs/nls/Kconfig
index a39edc4..2fb92e5 100644
--- a/fs/nls/Kconfig
+++ b/fs/nls/Kconfig
@@ -4,6 +4,7 @@
 
 menuconfig NLS
 	tristate "Native language support"
+	select NLS_BASE
 	---help---
 	  The base Native Language Support. A number of filesystems
 	  depend on it (e.g. FAT, JOLIET, NT, BEOS filesystems), as well
@@ -17,6 +18,19 @@ menuconfig NLS
 
 if NLS
 
+config NLS_BASE
+	bool "Base NLS functions"
+	depends on ACPI || DMI
+	default y
+	---help---
+	  The base NLS support functions which handle unicode traslations.
+
+	  If unsure, say Y.
+
+	  This config option is selected by ACPI && DMI && NLS as the
+	  functions defined here are needed in vmlinux and if built as
+	  module cause build issues.
+
 config NLS_DEFAULT
 	string "Default NLS Option"
 	default "iso8859-1"
diff --git a/fs/nls/Makefile b/fs/nls/Makefile
index f499dd7..dde741f 100644
--- a/fs/nls/Makefile
+++ b/fs/nls/Makefile
@@ -2,7 +2,7 @@
 # Makefile for native language support
 #
 
-obj-$(CONFIG_NLS)		+= nls_base.o
+obj-$(CONFIG_NLS_BASE)		+= nls_base.o
 
 obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
 obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o
-- 
1.7.3.1

With regards,
Narendra K

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
@ 2011-02-01 16:28                       ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-02-01 16:28 UTC (permalink / raw)
  To: jbarnes
  Cc: sfr, lenb, linux-kernel, linux-next, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Fri, Jan 28, 2011 at 10:15:18PM +0530, Jesse Barnes wrote:
> > > > > 
> > > > > Even on platforms that don't support ACPI or DMI ...
> > > > > 
> > > > > You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> > > > > CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> > > > > DMI and NLS?
> > > > 
> > > > Hi Stephen,
> > > > 
> > > > Thank you for the suggestions. 
> > > > 
> > > > I agree with your suggestion that we should compile nls_base.o
> > > > conditionally, only when ACPI || DMI || NLS. I have introduced a bew
> > > > config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.
> > > > 
> > > > V1 -> V2:
> > > > 
> > > > 1. Conditionally compile fs/nls/nls_base.c by introducing a new config
> > > > option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
> > > > Behavior of the rest of the files under fs/nls is not changed.
> > > > 
> > > > From: Narendra K <narendra_k@dell.com>
> > > > Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> > > 
> > > Hi,
> > > 
> > > Please let me know if there are any concerns with Version 2 of the patch.
> > > If it looks good please consider it for inclusion.
> > 
> > Hi Jesse,
> > 
> > Please let me know if there are any concerns with this patch. If it is
> > acceptable, please consider this for inclusion.
> 
> I think the fs stuff will have to get an ack from Al.  If he doesn't
> like it, see my earlier mail for another suggestion.

Hi Al,

Please let me know if there are any concerns with this patch. If not,
please ack this patch.

I have attached the patch here for your reference -

From: Narendra K <narendra_k@dell.com>
Subject: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig

This patch fixes the following build breakage introduced by the patch
PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
(previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).

http://marc.info/?l=linux-pci&m=129313294112736&w=1

drivers/built-in.o: In function `T.647':
pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'

This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
into vmlinux.

This is fixed by making fs/nls/nls_base.c compile conditionally into
vmlinux by introducing a new config option CONFIG_NLS_BASE which is
selected by (ACPI || DMI || NLS).

Signed-off-by: Narendra K <narendra_k@dell.com>
---
 fs/Makefile     |    2 +-
 fs/nls/Kconfig  |   14 ++++++++++++++
 fs/nls/Makefile |    2 +-
 3 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/fs/Makefile b/fs/Makefile
index a7f7cef..1e78b9b 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
 obj-$(CONFIG_EXPORTFS)		+= exportfs/
 obj-$(CONFIG_NFSD)		+= nfsd/
 obj-$(CONFIG_LOCKD)		+= lockd/
-obj-$(CONFIG_NLS)		+= nls/
+obj-y				+= nls/
 obj-$(CONFIG_SYSV_FS)		+= sysv/
 obj-$(CONFIG_CIFS)		+= cifs/
 obj-$(CONFIG_NCP_FS)		+= ncpfs/
diff --git a/fs/nls/Kconfig b/fs/nls/Kconfig
index a39edc4..2fb92e5 100644
--- a/fs/nls/Kconfig
+++ b/fs/nls/Kconfig
@@ -4,6 +4,7 @@
 
 menuconfig NLS
 	tristate "Native language support"
+	select NLS_BASE
 	---help---
 	  The base Native Language Support. A number of filesystems
 	  depend on it (e.g. FAT, JOLIET, NT, BEOS filesystems), as well
@@ -17,6 +18,19 @@ menuconfig NLS
 
 if NLS
 
+config NLS_BASE
+	bool "Base NLS functions"
+	depends on ACPI || DMI
+	default y
+	---help---
+	  The base NLS support functions which handle unicode traslations.
+
+	  If unsure, say Y.
+
+	  This config option is selected by ACPI && DMI && NLS as the
+	  functions defined here are needed in vmlinux and if built as
+	  module cause build issues.
+
 config NLS_DEFAULT
 	string "Default NLS Option"
 	default "iso8859-1"
diff --git a/fs/nls/Makefile b/fs/nls/Makefile
index f499dd7..dde741f 100644
--- a/fs/nls/Makefile
+++ b/fs/nls/Makefile
@@ -2,7 +2,7 @@
 # Makefile for native language support
 #
 
-obj-$(CONFIG_NLS)		+= nls_base.o
+obj-$(CONFIG_NLS_BASE)		+= nls_base.o
 
 obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
 obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o
-- 
1.7.3.1

With regards,
Narendra K

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
  2011-01-28 16:45                     ` Jesse Barnes
@ 2011-02-01 16:59                       ` Narendra_K
  -1 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-02-01 16:59 UTC (permalink / raw)
  To: jbarnes, viro
  Cc: sfr, lenb, linux-kernel, linux-next, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Fri, Jan 28, 2011 at 10:15:18PM +0530, Jesse Barnes wrote:
> > > > > Even on platforms that don't support ACPI or DMI ...
> > > > > 
> > > > > You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> > > > > CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> > > > > DMI and NLS?
> > > > 
> > > > Hi Stephen,
> > > > 
> > > > Thank you for the suggestions. 
> > > > 
> > > > I agree with your suggestion that we should compile nls_base.o
> > > > conditionally, only when ACPI || DMI || NLS. I have introduced a bew
> > > > config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.
> > > > 
> > > > V1 -> V2:
> > > > 
> > > > 1. Conditionally compile fs/nls/nls_base.c by introducing a new config
> > > > option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
> > > > Behavior of the rest of the files under fs/nls is not changed.
> > > > 
> > > > From: Narendra K <narendra_k@dell.com>
> > > > Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> > > 
> > > Hi,
> > > 
> > > Please let me know if there are any concerns with Version 2 of the patch.
> > > If it looks good please consider it for inclusion.
> > 
> > Hi Jesse,
> > 
> > Please let me know if there are any concerns with this patch. If it is
> > acceptable, please consider this for inclusion.
> 
> I think the fs stuff will have to get an ack from Al.  If he doesn't
> like it, see my earlier mail for another suggestion.

[Resending as i missed copying Al]

Hi Al,

Please let me know if there are any concerns with this patch. If not,
please ack this patch.

I have attached the patch here for your reference.

From: Narendra K <narendra_k@dell.com>
Subject: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig

This patch fixes the following build breakage introduced by the patch
PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
(previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).

http://marc.info/?l=linux-pci&m=129313294112736&w=1

drivers/built-in.o: In function `T.647':
pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'

This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
into vmlinux.

This is fixed by making fs/nls/nls_base.c compile conditionally into
vmlinux by introducing a new config option CONFIG_NLS_BASE which is
selected by (ACPI || DMI || NLS).

Signed-off-by: Narendra K <narendra_k@dell.com>
---
 fs/Makefile     |    2 +-
 fs/nls/Kconfig  |   14 ++++++++++++++
 fs/nls/Makefile |    2 +-
 3 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/fs/Makefile b/fs/Makefile
index a7f7cef..1e78b9b 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
 obj-$(CONFIG_EXPORTFS)		+= exportfs/
 obj-$(CONFIG_NFSD)		+= nfsd/
 obj-$(CONFIG_LOCKD)		+= lockd/
-obj-$(CONFIG_NLS)		+= nls/
+obj-y				+= nls/
 obj-$(CONFIG_SYSV_FS)		+= sysv/
 obj-$(CONFIG_CIFS)		+= cifs/
 obj-$(CONFIG_NCP_FS)		+= ncpfs/
diff --git a/fs/nls/Kconfig b/fs/nls/Kconfig
index a39edc4..2fb92e5 100644
--- a/fs/nls/Kconfig
+++ b/fs/nls/Kconfig
@@ -4,6 +4,7 @@
 
 menuconfig NLS
 	tristate "Native language support"
+	select NLS_BASE
 	---help---
 	  The base Native Language Support. A number of filesystems
 	  depend on it (e.g. FAT, JOLIET, NT, BEOS filesystems), as well
@@ -17,6 +18,19 @@ menuconfig NLS
 
 if NLS
 
+config NLS_BASE
+	bool "Base NLS functions"
+	depends on ACPI || DMI
+	default y
+	---help---
+	  The base NLS support functions which handle unicode traslations.
+
+	  If unsure, say Y.
+
+	  This config option is selected by ACPI && DMI && NLS as the
+	  functions defined here are needed in vmlinux and if built as
+	  module cause build issues.
+
 config NLS_DEFAULT
 	string "Default NLS Option"
 	default "iso8859-1"
diff --git a/fs/nls/Makefile b/fs/nls/Makefile
index f499dd7..dde741f 100644
--- a/fs/nls/Makefile
+++ b/fs/nls/Makefile
@@ -2,7 +2,7 @@
 # Makefile for native language support
 #
 
-obj-$(CONFIG_NLS)		+= nls_base.o
+obj-$(CONFIG_NLS_BASE)		+= nls_base.o
 
 obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
 obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o
-- 
1.7.3.1

With regards,
Narendra K

^ permalink raw reply related	[flat|nested] 31+ messages in thread

* Re: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
@ 2011-02-01 16:59                       ` Narendra_K
  0 siblings, 0 replies; 31+ messages in thread
From: Narendra_K @ 2011-02-01 16:59 UTC (permalink / raw)
  To: jbarnes, viro
  Cc: sfr, lenb, linux-kernel, linux-next, Matt_Domsch, Charles_Rose,
	Surya_Prabhakar

On Fri, Jan 28, 2011 at 10:15:18PM +0530, Jesse Barnes wrote:
> > > > > Even on platforms that don't support ACPI or DMI ...
> > > > > 
> > > > > You should really restrict this to CONFIG_ACPI || CONFIG_DMI ||
> > > > > CONFIG_NLS ... maybe create a CONFIG_NLS_BASE that is selected by ACPI,
> > > > > DMI and NLS?
> > > > 
> > > > Hi Stephen,
> > > > 
> > > > Thank you for the suggestions. 
> > > > 
> > > > I agree with your suggestion that we should compile nls_base.o
> > > > conditionally, only when ACPI || DMI || NLS. I have introduced a bew
> > > > config option CONFIG_NLS_BASE and made ACPI, DMI and NLS select it.
> > > > 
> > > > V1 -> V2:
> > > > 
> > > > 1. Conditionally compile fs/nls/nls_base.c by introducing a new config
> > > > option CONFIG_NLS_BASE, which is selected by (ACPI || DMI || NLS).
> > > > Behavior of the rest of the files under fs/nls is not changed.
> > > > 
> > > > From: Narendra K <narendra_k@dell.com>
> > > > Subject: [PATCH V2] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig
> > > 
> > > Hi,
> > > 
> > > Please let me know if there are any concerns with Version 2 of the patch.
> > > If it looks good please consider it for inclusion.
> > 
> > Hi Jesse,
> > 
> > Please let me know if there are any concerns with this patch. If it is
> > acceptable, please consider this for inclusion.
> 
> I think the fs stuff will have to get an ack from Al.  If he doesn't
> like it, see my earlier mail for another suggestion.

[Resending as i missed copying Al]

Hi Al,

Please let me know if there are any concerns with this patch. If not,
please ack this patch.

I have attached the patch here for your reference.

From: Narendra K <narendra_k@dell.com>
Subject: [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig

This patch fixes the following build breakage introduced by the patch
PCI:export ACPI _DSM provided firmware instance number and string to sysfs.
(previously commit a6247cd4be20cb5439db5cb7b0b6cc67fdc8e2a2).

http://marc.info/?l=linux-pci&m=129313294112736&w=1

drivers/built-in.o: In function `T.647':
pci-label.c:(.text+0x28514): undefined reference to `utf16s_to_utf8s'

This happens because 'make allmodconfig' sets CONFIG_NLS=m and makes
'utf16s_to_utf8s` unavailable to drivers/pci/pci-label.o which is built
into vmlinux.

This is fixed by making fs/nls/nls_base.c compile conditionally into
vmlinux by introducing a new config option CONFIG_NLS_BASE which is
selected by (ACPI || DMI || NLS).

Signed-off-by: Narendra K <narendra_k@dell.com>
---
 fs/Makefile     |    2 +-
 fs/nls/Kconfig  |   14 ++++++++++++++
 fs/nls/Makefile |    2 +-
 3 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/fs/Makefile b/fs/Makefile
index a7f7cef..1e78b9b 100644
--- a/fs/Makefile
+++ b/fs/Makefile
@@ -86,7 +86,7 @@ obj-$(CONFIG_NFS_FS)		+= nfs/
 obj-$(CONFIG_EXPORTFS)		+= exportfs/
 obj-$(CONFIG_NFSD)		+= nfsd/
 obj-$(CONFIG_LOCKD)		+= lockd/
-obj-$(CONFIG_NLS)		+= nls/
+obj-y				+= nls/
 obj-$(CONFIG_SYSV_FS)		+= sysv/
 obj-$(CONFIG_CIFS)		+= cifs/
 obj-$(CONFIG_NCP_FS)		+= ncpfs/
diff --git a/fs/nls/Kconfig b/fs/nls/Kconfig
index a39edc4..2fb92e5 100644
--- a/fs/nls/Kconfig
+++ b/fs/nls/Kconfig
@@ -4,6 +4,7 @@
 
 menuconfig NLS
 	tristate "Native language support"
+	select NLS_BASE
 	---help---
 	  The base Native Language Support. A number of filesystems
 	  depend on it (e.g. FAT, JOLIET, NT, BEOS filesystems), as well
@@ -17,6 +18,19 @@ menuconfig NLS
 
 if NLS
 
+config NLS_BASE
+	bool "Base NLS functions"
+	depends on ACPI || DMI
+	default y
+	---help---
+	  The base NLS support functions which handle unicode traslations.
+
+	  If unsure, say Y.
+
+	  This config option is selected by ACPI && DMI && NLS as the
+	  functions defined here are needed in vmlinux and if built as
+	  module cause build issues.
+
 config NLS_DEFAULT
 	string "Default NLS Option"
 	default "iso8859-1"
diff --git a/fs/nls/Makefile b/fs/nls/Makefile
index f499dd7..dde741f 100644
--- a/fs/nls/Makefile
+++ b/fs/nls/Makefile
@@ -2,7 +2,7 @@
 # Makefile for native language support
 #
 
-obj-$(CONFIG_NLS)		+= nls_base.o
+obj-$(CONFIG_NLS_BASE)		+= nls_base.o
 
 obj-$(CONFIG_NLS_CODEPAGE_437)	+= nls_cp437.o
 obj-$(CONFIG_NLS_CODEPAGE_737)	+= nls_cp737.o
-- 
1.7.3.1

With regards,
Narendra K

^ permalink raw reply related	[flat|nested] 31+ messages in thread

end of thread, other threads:[~2011-02-01 17:00 UTC | newest]

Thread overview: 31+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-01-12 20:10 CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure Narendra_K
2011-01-12 20:10 ` Narendra_K
2011-01-13  0:02 ` Jesse Barnes
2011-01-13  0:02   ` Jesse Barnes
2011-01-13  3:23   ` Len Brown
2011-01-13 15:55     ` Jesse Barnes
2011-01-13 16:03       ` Narendra_K
2011-01-13 16:03         ` Narendra_K
2011-01-14 15:22         ` [PATCH] Fix build failure when CONFIG_NLS is set to 'm' by allmodconfig Narendra_K
2011-01-14 15:22           ` Narendra_K
2011-01-14 15:29           ` Sedat Dilek
2011-01-14 16:06             ` Narendra_K
2011-01-14 16:06               ` Narendra_K
2011-01-14 21:09           ` Stephen Rothwell
2011-01-14 21:09             ` Stephen Rothwell
2011-01-17 19:28             ` Narendra_K
2011-01-17 19:28               ` Narendra_K
2011-01-20 18:41               ` Narendra_K
2011-01-20 18:41                 ` Narendra_K
2011-01-28 15:30                 ` Narendra_K
2011-01-28 15:30                   ` Narendra_K
2011-01-28 16:45                   ` Jesse Barnes
2011-01-28 16:45                     ` Jesse Barnes
2011-02-01 16:28                     ` Narendra_K
2011-02-01 16:28                       ` Narendra_K
2011-02-01 16:59                     ` Narendra_K
2011-02-01 16:59                       ` Narendra_K
2011-01-14 17:14         ` CONFIG_NLS=m resulting in undefined reference to utf16s_to_utf8s causing build failure Jesse Barnes
2011-01-14 17:14           ` Jesse Barnes
2011-01-13 16:46     ` Narendra_K
2011-01-13 16:46       ` Narendra_K

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.