Re: [stable] 2.6.23 regression: top displaying 9999% CPU usage

2007-10-30 Thread Otavio Salvador
Ingo Molnar [EMAIL PROTECTED] writes:

 * Frans Pop [EMAIL PROTECTED] wrote:

 On Monday 29 October 2007, Balbir Singh wrote:
  We'll also need this additional patch (untested),
 
 OK. Both patches together do the trick. Gave it a nice long test run and got 
 no more weirdness.
 Tested-by: Frans Pop [EMAIL PROTECTED]

 cool, thanks! I've queued it up for the next scheduler batch.

It would be nice to put those two on stable point release too.

-- 
O T A V I OS A L V A D O R
-
 E-mail: [EMAIL PROTECTED]  UIN: 5906116
 GNU/Linux User: 239058 GPG ID: 49A5F855
 Home Page: http://otavio.ossystems.com.br
-
Microsoft sells you Windows ... Linux gives
 you the whole house.
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Build Failure with 2.6.24-rc1

2007-10-24 Thread Otavio Salvador
Chris Holvenstot [EMAIL PROTECTED] writes:

 When attempting to build the 2.6.24-rc1 kernel:


 arch/x86/kernel/built-in.o: In function `smp_send_nmi_allbutself':
 /build/linux/arch/x86/kernel/crash.c:85: undefined reference to
 `genapic'
 make: *** [.tmp_vmlinux1] Error 1

Use the patch that Ingo sent on Message-ID: [EMAIL PROTECTED]

-- 
O T A V I OS A L V A D O R
-
 E-mail: [EMAIL PROTECTED]  UIN: 5906116
 GNU/Linux User: 239058 GPG ID: 49A5F855
 Home Page: http://otavio.ossystems.com.br
-
Microsoft sells you Windows ... Linux gives
 you the whole house.
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Linux 3.8 broken for MacBookAir5,1

2013-02-09 Thread Otavio Salvador
Hello,

On Sat, Jan 12, 2013 at 8:41 PM, Otavio Salvador
ota...@ossystems.com.br wrote:
 Today I tried to update my kernel from 3.7.2 to 3.8-rc3 and I had no
 success; I used localmodconfig to generate the .config for my machine
 but keyboard does not work.

 Using same generated .config with 3.7.2 works fine.

 Anyone has a clue about?

I finally found time to do a bisect and I found:

commit adfa79d1c06a32650332930ca4c488ca570b3407
Author: Alan Stern st...@rowland.harvard.edu
Date:   Thu Nov 1 11:13:04 2012 -0400

USB: EHCI: make ehci-pci a separate driver

This patch (as1625) splits the PCI portion of ehci-hcd out into its
own separate driver module, called ehci-pci.  Consistently with the
current practice, the decision whether to build this module is not
user-configurable.  If EHCI and PCI are enabled then the module will
be built, always.

Signed-off-by: Alan Stern st...@rowland.harvard.edu
CC: Felipe Balbi ba...@ti.com
Signed-off-by: Greg Kroah-Hartman gre...@linuxfoundation.org

As the problem start.

I do have EHCI and PCI enabled so it should be working. Any clue about
why it breaks it?

--
Otavio Salvador O.S. Systems
E-mail: ota...@ossystems.com.br  http://www.ossystems.com.br
Mobile: +55 53 9981-7854  http://projetos.ossystems.com.br
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Linux 3.8 broken for MacBookAir5,1

2013-02-09 Thread Otavio Salvador
On Sun, Feb 10, 2013 at 1:11 AM, Otavio Salvador
ota...@ossystems.com.br wrote:
 Hello,

 On Sat, Jan 12, 2013 at 8:41 PM, Otavio Salvador
 ota...@ossystems.com.br wrote:
 Today I tried to update my kernel from 3.7.2 to 3.8-rc3 and I had no
 success; I used localmodconfig to generate the .config for my machine
 but keyboard does not work.

 Using same generated .config with 3.7.2 works fine.

 Anyone has a clue about?

 I finally found time to do a bisect and I found:

 commit adfa79d1c06a32650332930ca4c488ca570b3407
 Author: Alan Stern st...@rowland.harvard.edu
 Date:   Thu Nov 1 11:13:04 2012 -0400

 USB: EHCI: make ehci-pci a separate driver

 This patch (as1625) splits the PCI portion of ehci-hcd out into its
 own separate driver module, called ehci-pci.  Consistently with the
 current practice, the decision whether to build this module is not
 user-configurable.  If EHCI and PCI are enabled then the module will
 be built, always.

 Signed-off-by: Alan Stern st...@rowland.harvard.edu
 CC: Felipe Balbi ba...@ti.com
 Signed-off-by: Greg Kroah-Hartman gre...@linuxfoundation.org

 As the problem start.

 I do have EHCI and PCI enabled so it should be working. Any clue about
 why it breaks it?

If it is built-in it works. So it fails just when used as a module.

-- 
Otavio Salvador O.S. Systems
E-mail: ota...@ossystems.com.br  http://www.ossystems.com.br
Mobile: +55 53 9981-7854  http://projetos.ossystems.com.br
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Linux 3.8 broken for MacBookAir5,1

2013-02-10 Thread Otavio Salvador
On Sun, Feb 10, 2013 at 12:47 PM, Alan Stern st...@rowland.harvard.edu wrote:
 On Sun, 10 Feb 2013, Otavio Salvador wrote:
 I do have EHCI and PCI enabled so it should be working. Any clue about
 why it breaks it?

 Perhaps your system is not loading the new ehci-pci kernel module.

Yes; it should be the cause as building it built-in makes it work.
However it is a regression from my point of view.

Those are the controllers I have in my system:

00:14.0 USB controller [0c03]: Intel Corporation 7 Series/C210 Series
Chipset Family USB xHCI Host Controller [8086:1e31] (rev 04)
00:1a.0 USB controller [0c03]: Intel Corporation 7 Series/C210 Series
Chipset Family USB Enhanced Host Controller #2 [8086:1e2d] (rev 04)
00:1d.0 USB controller [0c03]: Intel Corporation 7 Series/C210 Series
Chipset Family USB Enhanced Host Controller #1 [8086:1e26] (rev 04)

I thought the ehci-pci module would be load for every ehci PCI; What
do you think?

--
Otavio Salvador O.S. Systems
E-mail: ota...@ossystems.com.br  http://www.ossystems.com.br
Mobile: +55 53 9981-7854  http://projetos.ossystems.com.br
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Linux 3.8 broken for MacBookAir5,1

2013-02-18 Thread Otavio Salvador
On Mon, Feb 18, 2013 at 7:09 PM, Alan Stern st...@rowland.harvard.edu wrote:
 On Sun, 10 Feb 2013, Otavio Salvador wrote:

 On Sun, Feb 10, 2013 at 12:47 PM, Alan Stern st...@rowland.harvard.edu 
 wrote:
  On Sun, 10 Feb 2013, Otavio Salvador wrote:
  I do have EHCI and PCI enabled so it should be working. Any clue about
  why it breaks it?
 
  Perhaps your system is not loading the new ehci-pci kernel module.

 Yes; it should be the cause as building it built-in makes it work.
 However it is a regression from my point of view.

 Those are the controllers I have in my system:

 00:14.0 USB controller [0c03]: Intel Corporation 7 Series/C210 Series
 Chipset Family USB xHCI Host Controller [8086:1e31] (rev 04)
 00:1a.0 USB controller [0c03]: Intel Corporation 7 Series/C210 Series
 Chipset Family USB Enhanced Host Controller #2 [8086:1e2d] (rev 04)
 00:1d.0 USB controller [0c03]: Intel Corporation 7 Series/C210 Series
 Chipset Family USB Enhanced Host Controller #1 [8086:1e26] (rev 04)

 I thought the ehci-pci module would be load for every ehci PCI; What
 do you think?

 The kernel can't guarantee anything about what driver modules are
 loaded.  That's up to userspace.  In particular, the initramfs image
 must be set up properly (if that is where these modules are loaded
 from).

But why kernel cannot load it if we have a PCI subsystem? Or do you
think my initrd did not put the module on the initramfs image?

-- 
Otavio Salvador O.S. Systems
E-mail: ota...@ossystems.com.br  http://www.ossystems.com.br
Mobile: +55 53 9981-7854  http://projetos.ossystems.com.br
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Linux 3.8 broken for MacBookAir5,1

2013-02-18 Thread Otavio Salvador
On Mon, Feb 18, 2013 at 7:38 PM, Alan Stern st...@rowland.harvard.edu wrote:
 On Mon, 18 Feb 2013, Otavio Salvador wrote:

  I thought the ehci-pci module would be load for every ehci PCI; What
  do you think?
 
  The kernel can't guarantee anything about what driver modules are
  loaded.  That's up to userspace.  In particular, the initramfs image
  must be set up properly (if that is where these modules are loaded
  from).

 But why kernel cannot load it if we have a PCI subsystem? Or do you
 think my initrd did not put the module on the initramfs image?

 That's exactly what I think.  See this message and the corresponding
 thread:

 http://marc.info/?l=linux-usbm=136074995914335w=2

Thanks Alan, this was the problem.

Regards,

-- 
Otavio Salvador O.S. Systems
E-mail: ota...@ossystems.com.br  http://www.ossystems.com.br
Mobile: +55 53 9981-7854  http://projetos.ossystems.com.br
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Boot freeze after/during PCI initialization

2012-08-13 Thread Otavio Salvador
On Thu, Aug 9, 2012 at 5:00 PM, Otavio Salvador ota...@ossystems.com.br wrote:
 Hello,

 One of machines we have freeze during initialization from time to time:

 freeze at: http://download.ossystems.com.br/~otavio/geode-freeze.jpg
 works at: http://download.ossystems.com.br/~otavio/geode-working-dmesg.txt

 This happens with 3.4 and 3.5 kernel and seems to not happen with 3.0.

 Any clue what might be causing it?

This seems to be the bug: https://bugzilla.kernel.org/show_bug.cgi?id=13941

It seems no progress has been done in properly identify the cause of
it (or the progress is not reported on the bug itself).

-- 
Otavio Salvador O.S. Systems
E-mail: ota...@ossystems.com.br  http://www.ossystems.com.br
Mobile: +55 53 9981-7854  http://projetos.ossystems.com.br
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Boot freeze after/during PCI initialization

2012-08-13 Thread Otavio Salvador
On Mon, Aug 13, 2012 at 10:36 AM, Otavio Salvador
ota...@ossystems.com.br wrote:
 On Thu, Aug 9, 2012 at 5:00 PM, Otavio Salvador ota...@ossystems.com.br 
 wrote:
 Hello,

 One of machines we have freeze during initialization from time to time:

 freeze at: http://download.ossystems.com.br/~otavio/geode-freeze.jpg
 works at: http://download.ossystems.com.br/~otavio/geode-working-dmesg.txt

 This happens with 3.4 and 3.5 kernel and seems to not happen with 3.0.

 Any clue what might be causing it?

 This seems to be the bug: https://bugzilla.kernel.org/show_bug.cgi?id=13941

 It seems no progress has been done in properly identify the cause of
 it (or the progress is not reported on the bug itself).

Checking closely the bug it is not the same issue. I am attaching the
dmidecode output on the machine.

-- 
Otavio Salvador O.S. Systems
E-mail: ota...@ossystems.com.br  http://www.ossystems.com.br
Mobile: +55 53 9981-7854  http://projetos.ossystems.com.br
# dmidecode 2.9
SMBIOS 2.3 present.
15 structures occupying 970 bytes.
Table at 0x000E0050.

Handle 0x, DMI type 0, 20 bytes
BIOS Information
Vendor: General Software, Inc.
Version: Embedded BIOS(R) w/StrongFrame(TM) Technology (001)
Release Date: 09/15/2009
Address: 0xE
Runtime Size: 128 kB
ROM Size: 512 kB
Characteristics:
ISA is supported
PCI is supported
APM is supported
BIOS is upgradeable
BIOS shadowing is allowed
Boot from CD is supported
Selectable boot is supported
BIOS ROM is socketed
Print screen service is supported (int 5h)
8042 keyboard services are supported (int 9h)
Serial services are supported (int 14h)
Printer services are supported (int 17h)
CGA/mono video services are supported (int 10h)
ACPI is supported
AGP is supported

Handle 0x0001, DMI type 1, 25 bytes
System Information
Manufacturer: Urmet Daruma
Product Name: MT1000 LX
Version: No System Version
Serial Number: No System Serial Number
UUID: Not Settable
Wake-up Type: Unknown

Handle 0x0002, DMI type 2, 8 bytes
Base Board Information
Manufacturer: Urmet Daruma
Product Name: MT1000 LX
Version: Board Revision B
Serial Number: No Board Serial Number

Handle 0x0003, DMI type 3, 17 bytes
Chassis Information
Manufacturer: No Enclosure Manufacturer
Type: Other
Lock: Not Present
Version: No Enclosure Version
Serial Number: No Enclosure Serial Number
Asset Tag: No Enclosure Asset Tag
Boot-up State: Unknown
Power Supply State: Unknown
Thermal State: Unknown
Security Status: Unknown
OEM Information: 0x

Handle 0x0004, DMI type 4, 35 bytes
Processor Information
Socket Designation: No Socket
Type: Central Processor
Family: Other
Manufacturer: AMD Corporation
ID: A2 05 00 00 3D A9 88 00
Version: Geode GX3 Processor
Voltage: 5.0 V
External Clock: 33 MHz
Max Speed: Unknown
Current Speed: Unknown
Status: Populated, Enabled
Upgrade: Unknown
L1 Cache Handle: 0x009F
L2 Cache Handle: 0x00A0
L3 Cache Handle: 0x009E
Serial Number: No Serial#
Asset Tag: No Asset Tag
Part Number: No Part#

Handle 0x009F, DMI type 7, 19 bytes
Cache Information
Socket Designation: Processor L1 Cache
Configuration: Enabled, Not Socketed, Level 1
Operational Mode: Write Back
Location: Internal
Installed Size: 32 KB
Maximum Size: 32 KB
Supported SRAM Types:
Unknown
Installed SRAM Type: Unknown
Speed: Unknown
Error Correction Type: Unknown
System Type: Unknown
Associativity: Unknown

Handle 0x00A0, DMI type 7, 19 bytes
Cache Information
Socket Designation: Processor L2 Cache
Configuration: Enabled, Not Socketed, Level 2
Operational Mode: Write Back
Location: Internal
Installed Size: 512 KB
Maximum Size: 512 KB
Supported SRAM Types:
Unknown
Installed SRAM Type: Unknown
Speed: Unknown
Error Correction Type: Unknown
System Type: Unknown
Associativity: Unknown

Handle 0x00BF, DMI type 16, 15 bytes
Physical Memory Array
Location: System Board Or Motherboard
Use: System Memory
Error Correction Type: Other
Maximum Capacity: 17392 kB
Error Information Handle: Not Provided
Number Of Devices: 2

Handle 0x00DF, DMI type 17, 27 bytes
Memory Device
Array Handle: 0x00BF
Error Information Handle: Not Provided

Re: USB looks to be restarting

2008-01-24 Thread Otavio Salvador
Alan Stern [EMAIL PROTECTED] writes:

  Does someone has any idea how to solve it?

 Unplug the device attached to port 2 of bus 1.  Apparently it is 
 spontaneously disconnecting and reconnecting itself over and over.

The machine power suply had problem and then it needed to be
replace. Doing it solved the issue.

Probably the power suply wasn't providing enough power.

-- 
O T A V I OS A L V A D O R
-
 E-mail: [EMAIL PROTECTED]  UIN: 5906116
 GNU/Linux User: 239058 GPG ID: 49A5F855
 Home Page: http://otavio.ossystems.com.br
-
Microsoft sells you Windows ... Linux gives
 you the whole house.
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


oops when using git gc --auto

2008-02-26 Thread Otavio Salvador
Hello,

Today I got this oops, someone has an idea of what's going wrong?

Unable to handle kernel paging request at 0200 RIP: 
 [802735c3] find_get_pages+0x3c/0x69
PGD 0 
Oops:  [1] SMP 
CPU 3 
Modules linked in: sha256_generic aes_generic aes_x86_64 cbc blkcipher 
nvidia(P) rfcomm l2cap bluetooth ac battery ipv6 nfs lockd nfs_acl sunrpc 
bridge ext2 mbcache dm_crypt tun kvm_intel kvm loop snd_usb_audio snd_usb_lib 
snd_rawmidi snd_hda_intel e1000e i2c_i801 serio_raw snd_seq_device snd_pcm 
intel_agp button snd_timer pcspkr psmouse snd_hwdep snd snd_page_alloc 
soundcore evdev i2c_core xfs dm_mirror dm_snapshot dm_mod raid0 md_mod sg 
sr_mod cdrom sd_mod usbhid hid usb_storage pata_marvell floppy ahci ata_generic 
libata scsi_mod ehci_hcd uhci_hcd thermal processor fan
Pid: 15684, comm: git Tainted: P2.6.24-1-amd64 #1
RIP: 0010:[802735c3]  [802735c3] find_get_pages+0x3c/0x69
RSP: 0018:8100394dfd98  EFLAGS: 00010097
RAX: 0009 RBX: 000e RCX: 0009
RDX: 0200 RSI: 000a RDI: 0040
RBP: 810042964350 R08: 0040 R09: 000a
R10: 8100425a06c8 R11: 000a R12: 000e
R13: 8100394dfdf8 R14: 810042964350 R15: 
FS:  2ae326df2190() GS:81007d7aeb40() knlGS:
CS:  0010 DS:  ES:  CR0: 8005003b
CR2: 0200 CR3: 358f9000 CR4: 26e0
DR0:  DR1:  DR2: 
DR3:  DR6: 0ff0 DR7: 0400
Process git (pid: 15684, threadinfo 8100394de000, task 8100359cd800)
Stack:  000d 8100394dfde8 000d 000e
 000e 802794d6 8100014a7768 80279b04
    
Call Trace:
 [802794d6] pagevec_lookup+0x17/0x1e
 [80279b04] truncate_inode_pages_range+0x108/0x2bd
 [802a9e3a] generic_delete_inode+0xbf/0x127
 [802a1a4d] do_unlinkat+0xd5/0x144
 [802989e2] sys_write+0x45/0x6e
 [8020be2e] system_call+0x7e/0x83


Code: 48 8b 02 25 00 40 02 00 48 3d 00 40 02 00 75 04 48 8b 52 10 
RIP  [802735c3] find_get_pages+0x3c/0x69
 RSP 8100394dfd98
CR2: 0200
---[ end trace cb43a9f4488b815a ]---

-- 
O T A V I OS A L V A D O R
-
 E-mail: [EMAIL PROTECTED]  UIN: 5906116
 GNU/Linux User: 239058 GPG ID: 49A5F855
 Home Page: http://otavio.ossystems.com.br
-
Microsoft sells you Windows ... Linux gives
 you the whole house.
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: oops when using git gc --auto

2008-02-26 Thread Otavio Salvador
Nick Piggin [EMAIL PROTECTED] writes:

 On Wednesday 27 February 2008 00:22, Otavio Salvador wrote:
 Hello,

 Today I got this oops, someone has an idea of what's going wrong?

 Unable to handle kernel paging request at 0200 RIP:
  [802735c3] find_get_pages+0x3c/0x69

 At this point, the most likely candidate is a memory corruption
 error, probably hardware. Can you run memtest86 for a few hours
 to get a bit more confidence in the hw (preferably overnight)?

Those memories are new, but I can try. No problem. Will get back to
you by tomorrow.

 I did recently see another quite similar corruption in the
 pagecache radix-tree, though. Coincidence maybe?

I hope not.

-- 
O T A V I OS A L V A D O R
-
 E-mail: [EMAIL PROTECTED]  UIN: 5906116
 GNU/Linux User: 239058 GPG ID: 49A5F855
 Home Page: http://otavio.ossystems.com.br
-
Microsoft sells you Windows ... Linux gives
 you the whole house.
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: oops when using git gc --auto

2008-02-26 Thread Otavio Salvador
Nick Piggin [EMAIL PROTECTED] writes:

 On Wednesday 27 February 2008 00:22, Otavio Salvador wrote:
 Hello,

 Today I got this oops, someone has an idea of what's going wrong?

 Unable to handle kernel paging request at 0200 RIP:
  [802735c3] find_get_pages+0x3c/0x69

 At this point, the most likely candidate is a memory corruption
 error, probably hardware. Can you run memtest86 for a few hours
 to get a bit more confidence in the hw (preferably overnight)?

 I did recently see another quite similar corruption in the
 pagecache radix-tree, though. Coincidence maybe?

I let it running at lunch time and all went OK. I've also let burnP6
running later and nothing happened. Looks like hw is OK.

I've just got another oops, with same kernel.

Unable to handle kernel paging request at 83006d922370 RIP: 
 [8027a79b] shrink_page_list+0x16f/0x570
PGD 0 
Oops:  [1] SMP 
CPU 2 
Modules linked in: sha256_generic aes_generic aes_x86_64 cbc blkcipher 
nvidia(P) rfcomm l2cap bluetooth ac battery ipv6 nfs lockd nfs_acl sunrpc 
bridge ext2 mbcache dm_crypt tun kvm_intel kvm loop snd_hda_intel snd_usb_audio 
snd_pcm snd_timer snd_usb_lib snd_rawmidi snd_seq_device snd_hwdep snd i2c_i801 
soundcore snd_page_alloc intel_agp serio_raw button pcspkr e1000e i2c_core 
psmouse evdev xfs dm_mirror dm_snapshot dm_mod raid0 md_mod sg sr_mod cdrom 
sd_mod usbhid hid pata_marvell usb_storage floppy ahci ata_generic libata 
scsi_mod uhci_hcd ehci_hcd thermal processor fan
Pid: 213, comm: kswapd0 Tainted: P2.6.24-1-amd64 #1
RIP: 0010:[8027a79b]  [8027a79b] 
shrink_page_list+0x16f/0x570
RSP: 0018:81007ac8bbe0  EFLAGS: 00010286
RAX: 00010009 RBX: 810001e888a8 RCX: 810001e888d0
RDX: 83006d922350 RSI: 0001 RDI: 810001e888a8
RBP: 81007d1b9258 R08: 81007d776407 R09: 
R10: 0009 R11: 0002 R12: 0001
R13: 81007ac8be70 R14: 81007ac8bda0 R15: 81007ac8be01
FS:  () GS:81007d776340() knlGS:
CS:  0010 DS: 0018 ES: 0018 CR0: 8005003b
CR2: 83006d922370 CR3: 6d4ac000 CR4: 26e0
DR0:  DR1:  DR2: 
DR3:  DR6: 4ff0 DR7: 0400
Process kswapd0 (pid: 213, threadinfo 81007ac8a000, task 81007cc03800)
Stack:  0006 0002 0002 0001
 810001dc79e0 810001dc7a18 810001dc7fc8 810001dc8000
  0001  0001
Call Trace:
 [80279da1] isolate_lru_pages+0x5d/0x1d9
 [80279da1] isolate_lru_pages+0x5d/0x1d9
 [8027acb9] shrink_inactive_list+0x11d/0x381
 [8027b002] shrink_zone+0xe5/0x108
 [8027b500] kswapd+0x2fc/0x49b
 [80413b5b] thread_return+0x3d/0xab
 [80247ff2] autoremove_wake_function+0x0/0x2e
 [8027b204] kswapd+0x0/0x49b
 [80247ed3] kthread+0x47/0x74
 [8020cc48] child_rip+0xa/0x12
 [80247e8c] kthread+0x0/0x74
 [8020cc3e] child_rip+0x0/0x12


Code: 48 83 7a 20 00 0f 85 47 03 00 00 48 8d 42 30 48 39 42 30 0f 
RIP  [8027a79b] shrink_page_list+0x16f/0x570
 RSP 81007ac8bbe0
CR2: 83006d922370
---[ end trace b01014a6540e7663 ]---

-- 
O T A V I OS A L V A D O R
-
 E-mail: [EMAIL PROTECTED]  UIN: 5906116
 GNU/Linux User: 239058 GPG ID: 49A5F855
 Home Page: http://otavio.ossystems.com.br
-
Microsoft sells you Windows ... Linux gives
 you the whole house.
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: PROBLEM: sata timeouts with intel 82801HB on amd64

2007-02-07 Thread Otavio Salvador
Trevor Offner Caira [EMAIL PROTECTED] writes:

 (3) Keywords: SATA, AHCI, modules, kernel, Intel.

Does your systems is being run using ata_piix or ahci driver?

-- 
O T A V I OS A L V A D O R
-
 E-mail: [EMAIL PROTECTED]  UIN: 5906116
 GNU/Linux User: 239058 GPG ID: 49A5F855
 Home Page: http://otavio.ossystems.com.br
-
Microsoft sells you Windows ... Linux gives
 you the whole house.
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH] Add PM_TRACE x86_64 support.

2007-02-07 Thread Otavio Salvador
Nigel Cunningham [EMAIL PROTECTED] writes:

 - for (tracedata = __tracedata_start ; tracedata  __tracedata_end ; 
 tracedata += 6) {
 + for (tracedata = __tracedata_start ; tracedata  __tracedata_end ; 
 tracedata += 2 + sizeof(unsigned long)) {

Could you split this line?

-- 
O T A V I OS A L V A D O R
-
 E-mail: [EMAIL PROTECTED]  UIN: 5906116
 GNU/Linux User: 239058 GPG ID: 49A5F855
 Home Page: http://otavio.ossystems.com.br
-
Microsoft sells you Windows ... Linux gives
 you the whole house.
-
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Linux 3.8 broken for MacBookAir5,1

2013-01-12 Thread Otavio Salvador
Hello,

Today I tried to update my kernel from 3.7.2 to 3.8-rc3 and I had no
success; I used localmodconfig to generate the .config for my machine
but keyboard does not work.

Using same generated .config with 3.7.2 works fine.

Anyone has a clue about?

--
Otavio Salvador O.S. Systems
E-mail: ota...@ossystems.com.br  http://www.ossystems.com.br
Mobile: +55 53 9981-7854  http://projetos.ossystems.com.br
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 2/5] ARM: mxs-lradc: Simplify mxs_lradc_trigger_init error handle

2013-07-15 Thread Otavio Salvador
As we have a 'ret' variable with the iio_trigger_register return, this
can be used as result.

Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
 drivers/staging/iio/adc/mxs-lradc.c | 6 ++
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/iio/adc/mxs-lradc.c 
b/drivers/staging/iio/adc/mxs-lradc.c
index d92c97a..6d41846 100644
--- a/drivers/staging/iio/adc/mxs-lradc.c
+++ b/drivers/staging/iio/adc/mxs-lradc.c
@@ -671,14 +671,12 @@ static int mxs_lradc_trigger_init(struct iio_dev *iio)
trig-ops = mxs_lradc_trigger_ops;
 
ret = iio_trigger_register(trig);
-   if (ret) {
+   if (ret)
iio_trigger_free(trig);
-   return ret;
-   }
 
iio-trig = trig;
 
-   return 0;
+   return ret;
 }
 
 static void mxs_lradc_trigger_remove(struct iio_dev *iio)
-- 
1.8.3.2

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 5/5] iio: add configuration option for debug support

2013-07-15 Thread Otavio Salvador
Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
 drivers/iio/Kconfig  | 7 +++
 drivers/iio/Makefile | 2 ++
 2 files changed, 9 insertions(+)

diff --git a/drivers/iio/Kconfig b/drivers/iio/Kconfig
index 9af763a..d1f06f2 100644
--- a/drivers/iio/Kconfig
+++ b/drivers/iio/Kconfig
@@ -12,6 +12,13 @@ menuconfig IIO
 
 if IIO
 
+config IIO_DEBUG
+   boolean Debug support for Industrial I/O
+   depends on DEBUG_KERNEL
+   help
+ Say yes to enable debug messaging (like dev_dbg and pr_debug),
+ sysfs, and debugfs support in Industrial I/O subsystem and drivers.
+
 config IIO_BUFFER
bool Enable buffer support within IIO
help
diff --git a/drivers/iio/Makefile b/drivers/iio/Makefile
index 7a3866c..6e43e5b 100644
--- a/drivers/iio/Makefile
+++ b/drivers/iio/Makefile
@@ -2,6 +2,8 @@
 # Makefile for the industrial I/O core.
 #
 
+ccflags-$(CONFIG_IIO_DEBUG) := -DDEBUG
+
 obj-$(CONFIG_IIO) += industrialio.o
 industrialio-y := industrialio-core.o industrialio-event.o inkern.o
 industrialio-$(CONFIG_IIO_BUFFER) += industrialio-buffer.o
-- 
1.8.3.2

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 4/5] ARM: dts: imx23-olinuxino: enable Low Resolution ADC

2013-07-15 Thread Otavio Salvador
The i.XM23 has a internal Low Resolution ADC; this enables the support
for this device.

Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
 arch/arm/boot/dts/imx23-olinuxino.dts | 4 
 1 file changed, 4 insertions(+)

diff --git a/arch/arm/boot/dts/imx23-olinuxino.dts 
b/arch/arm/boot/dts/imx23-olinuxino.dts
index d107c4a..fc766ae 100644
--- a/arch/arm/boot/dts/imx23-olinuxino.dts
+++ b/arch/arm/boot/dts/imx23-olinuxino.dts
@@ -69,6 +69,10 @@
};
 
apbx@8004 {
+   lradc@8005 {
+   status = okay;
+   };
+
duart: serial@8007 {
pinctrl-names = default;
pinctrl-0 = duart_pins_a;
-- 
1.8.3.2

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 1/5] ARM: dts: imx23-evk: enable USB PHY and controller

2013-07-15 Thread Otavio Salvador
The i.MX23EVK board provides a USB port so the USB PHY and controller
need to be enabled for it to be usable.

Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
 arch/arm/boot/dts/imx23-evk.dts | 10 ++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm/boot/dts/imx23-evk.dts b/arch/arm/boot/dts/imx23-evk.dts
index da0588a..dc3ab45 100644
--- a/arch/arm/boot/dts/imx23-evk.dts
+++ b/arch/arm/boot/dts/imx23-evk.dts
@@ -107,6 +107,16 @@
pinctrl-0 = duart_pins_a;
status = okay;
};
+
+   usbphy0: usbphy@8007c000 {
+   status = okay;
+   };
+   };
+   };
+
+   ahb@8008 {
+   usb0: usb@8008 {
+   status = okay;
};
};
 
-- 
1.8.3.2

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 3/5] ARM: dts: imx23-evk: enable Low Resolution ADC

2013-07-15 Thread Otavio Salvador
The i.XM23 has a internal Low Resolution ADC; this enables the support
for this device.

Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
 arch/arm/boot/dts/imx23-evk.dts | 5 +
 1 file changed, 5 insertions(+)

diff --git a/arch/arm/boot/dts/imx23-evk.dts b/arch/arm/boot/dts/imx23-evk.dts
index dc3ab45..185c7c0 100644
--- a/arch/arm/boot/dts/imx23-evk.dts
+++ b/arch/arm/boot/dts/imx23-evk.dts
@@ -90,6 +90,11 @@
};
 
apbx@8004 {
+   lradc@8005 {
+   status = okay;
+   fsl,lradc-touchscreen-wires = 4;
+   };
+
pwm: pwm@80064000 {
pinctrl-names = default;
pinctrl-0 = pwm2_pins_a;
-- 
1.8.3.2

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 2/5] ARM: mxs-lradc: Simplify mxs_lradc_trigger_init error handle

2013-07-15 Thread Otavio Salvador
On Mon, Jul 15, 2013 at 11:24 AM, Marek Vasut marek.va...@gmail.com wrote:
 Dear Otavio Salvador,

 As we have a 'ret' variable with the iio_trigger_register return, this
 can be used as result.

 Signed-off-by: Otavio Salvador ota...@ossystems.com.br
 ---
  drivers/staging/iio/adc/mxs-lradc.c | 6 ++
  1 file changed, 2 insertions(+), 4 deletions(-)

 diff --git a/drivers/staging/iio/adc/mxs-lradc.c
 b/drivers/staging/iio/adc/mxs-lradc.c index d92c97a..6d41846 100644
 --- a/drivers/staging/iio/adc/mxs-lradc.c
 +++ b/drivers/staging/iio/adc/mxs-lradc.c
 @@ -671,14 +671,12 @@ static int mxs_lradc_trigger_init(struct iio_dev
 *iio) trig-ops = mxs_lradc_trigger_ops;

   ret = iio_trigger_register(trig);
 - if (ret) {
 + if (ret)
   iio_trigger_free(trig);
 - return ret;
 - }

   iio-trig = trig;


 You are still setting iio-trig , you dont want to do that in case of failure

In this case it'd end being NULL I think, wouldn't it?

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://projetos.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 1/5] ARM: dts: imx23-evk: enable USB PHY and controller

2013-07-15 Thread Otavio Salvador
On Mon, Jul 15, 2013 at 12:39 PM, Fabio Estevam feste...@gmail.com wrote:
 Hi Otavio,

 On Mon, Jul 15, 2013 at 11:22 AM, Otavio Salvador
 ota...@ossystems.com.br wrote:
 The i.MX23EVK board provides a USB port so the USB PHY and controller
 need to be enabled for it to be usable.

 Signed-off-by: Otavio Salvador ota...@ossystems.com.br
 ---

 You should have Cc'd Shawn Guo on this series.

Oh; thanks for fix my mistake. I am new to kernel development :-)

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://projetos.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 5/5] iio: add configuration option for debug support

2013-07-16 Thread Otavio Salvador
On Tue, Jul 16, 2013 at 7:26 AM, Lars-Peter Clausen l...@metafoo.de wrote:
 On 07/16/2013 11:58 AM, Jonathan Cameron wrote:
 On 07/15/2013 03:22 PM, Otavio Salvador wrote:
 Signed-off-by: Otavio Salvador ota...@ossystems.com.br
 seems a sensible facility to have available.

 Applied to the togreg branch of iio.git

 Can you update the Kconfig help text?

Sure I can. Jonathan seem to have applied it so should I send a v2 or
a new patch?

 ---
  drivers/iio/Kconfig  | 7 +++
  drivers/iio/Makefile | 2 ++
  2 files changed, 9 insertions(+)

 diff --git a/drivers/iio/Kconfig b/drivers/iio/Kconfig
 index 9af763a..d1f06f2 100644
 --- a/drivers/iio/Kconfig
 +++ b/drivers/iio/Kconfig
 @@ -12,6 +12,13 @@ menuconfig IIO

  if IIO

 +config IIO_DEBUG
 +boolean Debug support for Industrial I/O
 +depends on DEBUG_KERNEL
 +help
 +  Say yes to enable debug messaging (like dev_dbg and pr_debug),
 +  sysfs, and debugfs support in Industrial I/O subsystem and drivers.

 This has nothing to do with either sysfs or debugfs support.

 Say yes to enable debug messaging (like dev_dbg and pr_debug)
 support in Industrial I/O subsystem and drivers.

?

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://projetos.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 1/5] ARM: dts: imx23-evk: enable USB PHY and controller

2013-07-16 Thread Otavio Salvador
On Tue, Jul 16, 2013 at 12:42 AM, Fabio Estevam feste...@gmail.com wrote:
 On Mon, Jul 15, 2013 at 11:22 AM, Otavio Salvador
 ota...@ossystems.com.br wrote:
 The i.MX23EVK board provides a USB port so the USB PHY and controller
 need to be enabled for it to be usable.

 Has this been tested? I don't see in this patch any code to enable USB power.

It does, I am using it.

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://projetos.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 1/5] ARM: dts: imx23-evk: enable USB PHY and controller

2013-07-16 Thread Otavio Salvador
On Mon, Jul 15, 2013 at 10:30 PM, Shawn Guo shawn@linaro.org wrote:
 On Mon, Jul 15, 2013 at 01:39:13PM -0300, Otavio Salvador wrote:
 On Mon, Jul 15, 2013 at 12:39 PM, Fabio Estevam feste...@gmail.com wrote:
  Hi Otavio,
 
  On Mon, Jul 15, 2013 at 11:22 AM, Otavio Salvador
  ota...@ossystems.com.br wrote:
  The i.MX23EVK board provides a USB port so the USB PHY and controller
  need to be enabled for it to be usable.
 
  Signed-off-by: Otavio Salvador ota...@ossystems.com.br
  ---
 
  You should have Cc'd Shawn Guo on this series.

 Oh; thanks for fix my mistake. I am new to kernel development :-)

 I'm on copy of patches 1, 3 and 4.  2 and 5 are missing?

I will prepare a v2, as per Jonathan feedback and will add you in all them.

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://projetos.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 2/5] ARM: mxs-lradc: Simplify mxs_lradc_trigger_init error handle

2013-07-16 Thread Otavio Salvador
On Mon, Jul 15, 2013 at 8:00 PM, Marek Vasut ma...@denx.de wrote:
 Dear Otavio Salvador,

 On Mon, Jul 15, 2013 at 11:24 AM, Marek Vasut marek.va...@gmail.com wrote:
  Dear Otavio Salvador,
 
  As we have a 'ret' variable with the iio_trigger_register return, this
  can be used as result.
 
  Signed-off-by: Otavio Salvador ota...@ossystems.com.br
  ---
 
   drivers/staging/iio/adc/mxs-lradc.c | 6 ++
   1 file changed, 2 insertions(+), 4 deletions(-)
 
  diff --git a/drivers/staging/iio/adc/mxs-lradc.c
  b/drivers/staging/iio/adc/mxs-lradc.c index d92c97a..6d41846 100644
  --- a/drivers/staging/iio/adc/mxs-lradc.c
  +++ b/drivers/staging/iio/adc/mxs-lradc.c
  @@ -671,14 +671,12 @@ static int mxs_lradc_trigger_init(struct iio_dev
  *iio) trig-ops = mxs_lradc_trigger_ops;
 
ret = iio_trigger_register(trig);
 
  - if (ret) {
  + if (ret)
 
iio_trigger_free(trig);
 
  - return ret;
  - }
 
iio-trig = trig;
 
  You are still setting iio-trig , you dont want to do that in case of
  failure

 In this case it'd end being NULL I think, wouldn't it?

 It won't, see the implementation in:

 drivers/iio/industrialio-trigger.c

Agreed; will drop this from v2.

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://projetos.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH v2 3/4] ARM: dts: imx23-olinuxino: enable Low Resolution ADC

2013-07-16 Thread Otavio Salvador
The i.XM23 has a internal Low Resolution ADC; this enables the support
for this device.

Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
Changes in v2: None

 arch/arm/boot/dts/imx23-olinuxino.dts | 4 
 1 file changed, 4 insertions(+)

diff --git a/arch/arm/boot/dts/imx23-olinuxino.dts 
b/arch/arm/boot/dts/imx23-olinuxino.dts
index d107c4a..fc766ae 100644
--- a/arch/arm/boot/dts/imx23-olinuxino.dts
+++ b/arch/arm/boot/dts/imx23-olinuxino.dts
@@ -69,6 +69,10 @@
};
 
apbx@8004 {
+   lradc@8005 {
+   status = okay;
+   };
+
duart: serial@8007 {
pinctrl-names = default;
pinctrl-0 = duart_pins_a;
-- 
1.8.3.2

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH v2 2/4] ARM: dts: imx23-evk: enable Low Resolution ADC

2013-07-16 Thread Otavio Salvador
The i.XM23 has a internal Low Resolution ADC; this enables the support
for this device.

Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
Changes in v2: None

 arch/arm/boot/dts/imx23-evk.dts | 5 +
 1 file changed, 5 insertions(+)

diff --git a/arch/arm/boot/dts/imx23-evk.dts b/arch/arm/boot/dts/imx23-evk.dts
index dc3ab45..185c7c0 100644
--- a/arch/arm/boot/dts/imx23-evk.dts
+++ b/arch/arm/boot/dts/imx23-evk.dts
@@ -90,6 +90,11 @@
};
 
apbx@8004 {
+   lradc@8005 {
+   status = okay;
+   fsl,lradc-touchscreen-wires = 4;
+   };
+
pwm: pwm@80064000 {
pinctrl-names = default;
pinctrl-0 = pwm2_pins_a;
-- 
1.8.3.2

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH v2 4/4] iio: add configuration option for debug support

2013-07-16 Thread Otavio Salvador
Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
Changes in v2:
- Rework Kconfig help (Lars-Peter Clausen)

 drivers/iio/Kconfig  | 7 +++
 drivers/iio/Makefile | 2 ++
 2 files changed, 9 insertions(+)

diff --git a/drivers/iio/Kconfig b/drivers/iio/Kconfig
index 9af763a..e5d1cfc 100644
--- a/drivers/iio/Kconfig
+++ b/drivers/iio/Kconfig
@@ -12,6 +12,13 @@ menuconfig IIO
 
 if IIO
 
+config IIO_DEBUG
+   boolean Debug support for Industrial I/O
+   depends on DEBUG_KERNEL
+   help
+ Say yes to enable debug messaging (like dev_dbg and pr_debug)
+ support in Industrial I/O subsystem and drivers.
+
 config IIO_BUFFER
bool Enable buffer support within IIO
help
diff --git a/drivers/iio/Makefile b/drivers/iio/Makefile
index 7a3866c..6e43e5b 100644
--- a/drivers/iio/Makefile
+++ b/drivers/iio/Makefile
@@ -2,6 +2,8 @@
 # Makefile for the industrial I/O core.
 #
 
+ccflags-$(CONFIG_IIO_DEBUG) := -DDEBUG
+
 obj-$(CONFIG_IIO) += industrialio.o
 industrialio-y := industrialio-core.o industrialio-event.o inkern.o
 industrialio-$(CONFIG_IIO_BUFFER) += industrialio-buffer.o
-- 
1.8.3.2

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH v2 1/4] ARM: dts: imx23-evk: enable USB PHY and controller

2013-07-16 Thread Otavio Salvador
The i.MX23EVK board provides a USB port so the USB PHY and controller
need to be enabled for it to be usable.

Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
Changes in v2: None

 arch/arm/boot/dts/imx23-evk.dts | 10 ++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm/boot/dts/imx23-evk.dts b/arch/arm/boot/dts/imx23-evk.dts
index da0588a..dc3ab45 100644
--- a/arch/arm/boot/dts/imx23-evk.dts
+++ b/arch/arm/boot/dts/imx23-evk.dts
@@ -107,6 +107,16 @@
pinctrl-0 = duart_pins_a;
status = okay;
};
+
+   usbphy0: usbphy@8007c000 {
+   status = okay;
+   };
+   };
+   };
+
+   ahb@8008 {
+   usb0: usb@8008 {
+   status = okay;
};
};
 
-- 
1.8.3.2

--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH v2 1/4] ARM: dts: imx23-evk: enable USB PHY and controller

2013-07-17 Thread Otavio Salvador
On Wed, Jul 17, 2013 at 12:50 AM, Shawn Guo shawn@linaro.org wrote:
 On Tue, Jul 16, 2013 at 09:56:12AM -0300, Otavio Salvador wrote:
 The i.MX23EVK board provides a USB port so the USB PHY and controller
 need to be enabled for it to be usable.

 Signed-off-by: Otavio Salvador ota...@ossystems.com.br

 There is a typo i.XM23 in commit log of patch #2 and #3.  I fixed them
 up and applied all 3.

Thanks Shawn :)

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://projetos.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Fwd: mxs-lradc oops when unloading module

2013-06-16 Thread Otavio Salvador
[ I am resending as it didn't make iio mailing list as the message
wasn't plain text ]

Hello,

When using mxs-lradc, as module, in a MX23 and unloading the driver,
it sometimes oops as:

[   46.34] Unable to handle kernel NULL pointer dereference at
virtual address 0005
[   46.34] pgd = c7744000
[   46.35] [0005] *pgd=46f4d831, *pte=, *ppte=
[   46.36] Internal error: Oops: 1 [#1] ARM
[   46.36] Modules linked in: mxs_lradc(C-) industrialio_triggered_buffer
[   46.36] CPU: 0 PID: 359 Comm: rmmod Tainted: G C
3.10.0-rc5+ #24
[   46.36] task: c6f6a200 ti: c680e000 task.ti: c680e000
[   46.36] PC is at module_put+0x18/0x80
[   46.36] LR is at iio_device_unregister_trigger_consumer+0x1c/0x28
[   46.36] pc : [c0063334]lr : [c0373808]psr: a013
[   46.36] sp : c680feb0  ip : 6013  fp : 01324008
[   46.36] r10: 0013  r9 : c680e000  r8 : 
[   46.36] r7 : c6ee9418  r6 : c0373808  r5 : c6ee8800  r4 : c6ee9810
[   46.36] r3 : 0001  r2 : c067a428  r1 : 02e0  r0 : c6ee8800
[   46.36] Flags: NzCv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment user
[   46.36] Control: 0005317f  Table: 47744000  DAC: 0015
[   46.36] Process rmmod (pid: 359, stack limit = 0xc680e1b8)
[   46.36] Stack: (0xc680feb0 to 0xc681)
[   46.36] fea0: c6ee9810
c6ee9400 c76cff80 c0373808
[   46.36] fec0: c6ee9410 c036f9bc c036f990 c6ee9418 c6ee9410
c02a9610 c6ee9434 c065fbe0
[   46.36] fee0: c77ccbe0 c024bc40  c6ee9400 
c74c0644 c680e000 bf0049c4
[   46.36] ff00: bf004940 c74c0610 bf00589c c02ae058 c02ae044
c02ac8f0 bf00589c c74c0610
[   46.36] ff20: bf00589c c02ad0dc bf0058dc bf00589c c065fe60
c02ac730 bf0058dc 
[   46.36] ff40: 0800 c0064010  5f73786d 6461726c
0063 c6f6a200 c680e000
[   46.36] ff60: c6f6a200 c000edcc 0001  c680e000
bec16e48 01324008 c005c754
[   46.36] ff80: 01324088 0800 01324088 01324088 0800
01324088 0081 c000ef08
[   46.36] ffa0:  c000ed40 01324088 0800 013240b8
0800 bec16c08 effc
[   46.36] ffc0: 01324088 0800 01324088 0081 0001
bec16c38 bec16e48 01324008
[   46.36] ffe0: 4d819ef0 bec16bf4 4d808768 4d721e6c 2010
013240b8 15401540 51110540
[   46.36] [c0063334] (module_put+0x18/0x80) from [c0373808]
(iio_device_unregister_trigger_consumer+0x1c/0x28)
[   46.36] [c0373808]
(iio_device_unregister_trigger_consumer+0x1c/0x28) from [c036f9bc]
(iio_dev_release+0x2c/0x6c)
[   46.36] [c036f9bc] (iio_dev_release+0x2c/0x6c) from
[c02a9610] (device_release+0x2c/0x90)
[   46.36] [c02a9610] (device_release+0x2c/0x90) from
[c024bc40] (kobject_release+0x48/0x7c)
[   46.36] [c024bc40] (kobject_release+0x48/0x7c) from
[bf0049c4] (mxs_lradc_remove+0x84/0x90 [mxs_lradc])
[   46.36] [bf0049c4] (mxs_lradc_remove+0x84/0x90 [mxs_lradc])
from [c02ae058] (platform_drv_remove+0x14/0x18)
[   46.36] [c02ae058] (platform_drv_remove+0x14/0x18) from
[c02ac8f0] (__device_release_driver+0x58/0xb4)
[   46.36] [c02ac8f0] (__device_release_driver+0x58/0xb4) from
[c02ad0dc] (driver_detach+0xb4/0xb8)
[   46.36] [c02ad0dc] (driver_detach+0xb4/0xb8) from
[c02ac730] (bus_remove_driver+0x7c/0xc0)
[   46.36] [c02ac730] (bus_remove_driver+0x7c/0xc0) from
[c0064010] (SyS_delete_module+0x150/0x26c)
[   46.36] [c0064010] (SyS_delete_module+0x150/0x26c) from
[c000ed40] (ret_fast_syscall+0x0/0x44)
[   46.36] Code: e1a0600e 08bd8070 e5953174 e59f2060 (e5931004)
[   46.65] ---[ end trace 7379015df3468e61 ]---

From what I could grasp, it might be related to the IIO subsystem but
I couldn't find the culprit.

It seems iio_device_unregister_trigger_consumer, as:

void iio_device_unregister_trigger_consumer(struct iio_dev *indio_dev)
{
/* Clean up an associated but not attached trigger reference */
if (indio_dev-trig)
iio_trigger_put(indio_dev-trig);
}

and , as:

static inline void iio_trigger_put(struct iio_trigger *trig)
{
module_put(trig-ops-owner);
put_device(trig-dev);
}

so, somehow the trig-ops is NULL here.

Do someone has a clue?

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://projetos.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: Fwd: mxs-lradc oops when unloading module

2013-06-24 Thread Otavio Salvador
On Sat, Jun 22, 2013 at 8:03 AM, Jonathan Cameron ji...@kernel.org wrote:
 From what I could grasp, it might be related to the IIO subsystem but
 I couldn't find the culprit.

 It seems iio_device_unregister_trigger_consumer, as:

 void iio_device_unregister_trigger_consumer(struct iio_dev *indio_dev)
 {
 /* Clean up an associated but not attached trigger reference */
 if (indio_dev-trig)
 iio_trigger_put(indio_dev-trig);
 }

 and , as:

 static inline void iio_trigger_put(struct iio_trigger *trig)
 {
 module_put(trig-ops-owner);
 put_device(trig-dev);
 }

 so, somehow the trig-ops is NULL here.

 Do someone has a clue?

 I think the issue is more core to iio trigger handling than that, you
 have just been unlucky enough to hit a bug that has been there a while.

 In iio_trigger_unregister we call
 iio_device_unregister which in turn calls device_del (as intended) and
 device_put (as not!).  Then we get an additional device_put from
 iio_trigger_free giving us one more than we should have an resulting
 in a double attempt to free the device.

 Could you try the following change and see if it solves the problem?
 (the comment abov is 'interesting' and stupid given I've long ago
 forgotten what it refers to, but it could be related to this issue...)

 From 238faf76acaa9214b0eb607742dd14b134469328 Mon Sep 17 00:00:00 2001
 From: Jonathan Cameron ji...@kernel.org
 Date: Sat, 22 Jun 2013 12:00:04 +0100
 Subject: [PATCH] iio:trigger: device_unregister-device_del to avoid double
  free

 iio_trigger unregistration and freeing has been separated in this
 code for some time, but it looks like the calls to the device
 handling were not appropriately updated.

 Signed-off-by: Jonathan Cameron ji...@kernel.org
 ---
  drivers/iio/industrialio-trigger.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

 diff --git a/drivers/iio/industrialio-trigger.c 
 b/drivers/iio/industrialio-trigger.c
 index 4d6c7d8..ea8a414 100644
 --- a/drivers/iio/industrialio-trigger.c
 +++ b/drivers/iio/industrialio-trigger.c
 @@ -104,7 +104,7 @@ void iio_trigger_unregister(struct iio_trigger *trig_info)

 ida_simple_remove(iio_trigger_ida, trig_info-id);
 /* Possible issue in here */
 -   device_unregister(trig_info-dev);
 +   device_del(trig_info-dev);
  }
  EXPORT_SYMBOL(iio_trigger_unregister);

Tested-by: Otavio Salvador ota...@ossystems.com.br

It does fix the Oops for me.

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://projetos.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: RCU bug with v3.17-rc3 ?

2014-10-11 Thread Otavio Salvador
Hello Russell,

On Sat, Oct 11, 2014 at 11:16 AM, Russell King - ARM Linux
li...@arm.linux.org.uk wrote:
 On Sat, Oct 11, 2014 at 11:54:32AM +0800, Peter Chen wrote:
 On Fri, Oct 10, 2014 at 08:44:33PM -0500, Nathan Lynch wrote:
  On 10/10/2014 11:25 AM, Russell King - ARM Linux wrote:
  
   Right, so GCC 4.8.{1,2} are totally unsuitable for kernel building (and
   it seems that this has been known about for some time.)
 
  Looking at http://gcc.gnu.org/PR58854 it seems that all 4.8.x for x  3
  are affected, as well as 4.9.0.
 
   We can blacklist these GCC versions quite easily.  We already have GCC
   3.3 blacklisted, and it's trivial to add others.  I would want to include
   some proper details about the bug, just like the other existing entries
   we already have in asm-offsets.c, where we name the functions that the
   compiler is known to break where appropriate.
 
  Before blacklisting anything, it's worth considering that simple version
  checks would break existing pre-4.8.3 compilers that have been patched
  for PR58854.  It looks like Yocto and Buildroot issued releases with
  patched 4.8.2 compilers well before the (fixed) 4.8.3 release.  I think
  the most we can reasonably do without breaking some correctly-behaving
  toolchains is to emit a warning.

 Yocto has PR58854 problem patch.

 http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/meta/recipes-devtools/gcc/gcc-4.8/0048-PR58854_fix_arm_apcs_epilogue.patch?h=daisy

 Right, and we can provide links to these in the comments above the #error
 so people have the right places to do a bit of research into whether their
 compiler is safe.

 It is unfortunate that they are indistinguishable from the broken versions,
 but that's really a distro problem for causing that issue themselves -
 especially given how serious this bug is.

What about checking if GCC_PR58854_FIXED is not defined for error? So
build systems and people could easily define it if they know their GCC
has the fix applied.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH v2] ARM: dts: warp: Add initial WaRP Board support

2015-03-02 Thread Otavio Salvador
The WaRP Board is a Wearable Reference Plaform. The board features:

 - Freescale i.MX6 SoloLite processor with 512MB of RAM
 - Freescale FXOS8700CQ 6-axis Xtrinsic sensor
 - Freescale Kinetis KL16 MCU
 - Freescale Xtrinsic MMA955xL intelligent motion sensing platform

The board implements a hybrid architecture to address the evolving
needs of the wearables market. The platform consists of a main board
and an example daughtercard with the ability to add additional
daughtercards for different usage models.

For more information about the project, visit:

 http://www.warpboard.org/

Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
 arch/arm/boot/dts/Makefile|   3 +-
 arch/arm/boot/dts/imx6sl-warp.dts | 190 ++
 2 files changed, 192 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/boot/dts/imx6sl-warp.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index a1c776b..1b49d57 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -299,7 +299,8 @@ dtb-$(CONFIG_SOC_IMX6Q) += \
imx6q-wandboard.dtb \
imx6q-wandboard-revb1.dtb
 dtb-$(CONFIG_SOC_IMX6SL) += \
-   imx6sl-evk.dtb
+   imx6sl-evk.dtb \
+   imx6sl-warp.dtb
 dtb-$(CONFIG_SOC_IMX6SX) += \
imx6sx-sabreauto.dtb \
imx6sx-sdb.dtb
diff --git a/arch/arm/boot/dts/imx6sl-warp.dts 
b/arch/arm/boot/dts/imx6sl-warp.dts
new file mode 100644
index 000..904efc4
--- /dev/null
+++ b/arch/arm/boot/dts/imx6sl-warp.dts
@@ -0,0 +1,190 @@
+/*
+ * Copyright 2014, 2015 O.S. Systems Software LTDA.
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This file is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public
+ * License along with this file; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
+ * MA 02110-1301 USA
+ *
+ * Or, alternatively,
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the Software), to deal in the Software without
+ * restriction, including without limitation the rights to use,
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+/dts-v1/;
+
+#include imx6sl.dtsi
+
+/ {
+   model = WaRP Board;
+   compatible = warp,imx6sl-warp, fsl,imx6sl;
+
+   memory {
+   reg = 0x8000 0x2000;
+   };
+
+   regulators {
+   compatible = simple-bus;
+   #address-cells = 1;
+   #size-cells = 0;
+
+   reg_usb_otg1_vbus: regulator@0 {
+   compatible = regulator-fixed;
+   reg = 0;
+   regulator-name = usb_otg1_vbus;
+   regulator-min-microvolt = 500;
+   regulator-max-microvolt = 500;
+   gpio = gpio4 0 0;
+   enable-active-high;
+   };
+
+   reg_usb_otg2_vbus: regulator@1 {
+   compatible = regulator-fixed;
+   reg = 1;
+   regulator-name = usb_otg2_vbus;
+   regulator-min-microvolt = 500;
+   regulator-max-microvolt = 500;
+   gpio = gpio4 2 0;
+   enable-active-high;
+   };
+
+   reg_1p8v

Re: [PATCH] ARM: dts: warp: Add initial WaRP Board support

2015-03-02 Thread Otavio Salvador
Hello Shawn,

On Tue, Mar 3, 2015 at 12:29 AM, Shawn Guo shawn@linaro.org wrote:
 On Wed, Feb 25, 2015 at 02:02:19PM -0300, Otavio Salvador wrote:
 The WaRP Board is a Wearable Reference Plaform. The board features:

  - Freescale i.MX6 SoloLite processor with 512MB of RAM
  - Freescale FXOS8700CQ 6-axis Xtrinsic sensor
  - Freescale Kinetis KL16 MCU
  - Freescale Xtrinsic MMA955xL intelligent motion sensing platform

 The board implements a hybrid architecture to address the evolving
 needs of the wearables market. The platform consists of a main board
 and an example daughtercard with the ability to add additional
 daughtercards for different usage models.

 For more information about the project, visit:

  http://www.warpboard.org/

 Signed-off-by: Otavio Salvador ota...@ossystems.com.br

 Pretty neat!  Only one comment about dts license below.

 ---
  arch/arm/boot/dts/Makefile|   3 +-
  arch/arm/boot/dts/imx6sl-warp.dts | 154 
 ++
  2 files changed, 156 insertions(+), 1 deletion(-)
  create mode 100644 arch/arm/boot/dts/imx6sl-warp.dts

 diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
 index a1c776b..1b49d57 100644
 --- a/arch/arm/boot/dts/Makefile
 +++ b/arch/arm/boot/dts/Makefile
 @@ -299,7 +299,8 @@ dtb-$(CONFIG_SOC_IMX6Q) += \
   imx6q-wandboard.dtb \
   imx6q-wandboard-revb1.dtb
  dtb-$(CONFIG_SOC_IMX6SL) += \
 - imx6sl-evk.dtb
 + imx6sl-evk.dtb \
 + imx6sl-warp.dtb
  dtb-$(CONFIG_SOC_IMX6SX) += \
   imx6sx-sabreauto.dtb \
   imx6sx-sdb.dtb
 diff --git a/arch/arm/boot/dts/imx6sl-warp.dts 
 b/arch/arm/boot/dts/imx6sl-warp.dts
 new file mode 100644
 index 000..dadb92f
 --- /dev/null
 +++ b/arch/arm/boot/dts/imx6sl-warp.dts
 @@ -0,0 +1,154 @@
 +/*
 + * Copyright 2014, 2015 O.S. Systems Software LTDA.
 + *
 + * The code contained herein is licensed under the GNU General Public
 + * License. You may obtain a copy of the GNU General Public License
 + * Version 2 or later at the following locations:
 + *
 + * http://www.opensource.org/licenses/gpl-license.html
 + * http://www.gnu.org/copyleft/gpl.html
 + */

 It's preferred to use GPL/X11 dual license for new dts files.  See
 arch/arm/boot/dts/imx6q-tbs2910.dts for example.

I sent a v2 changing it. Thanks for the remark :)

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
--
To unsubscribe from this list: send the line unsubscribe linux-kernel in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH] ARM: dts: warp: Add initial WaRP Board support

2015-02-25 Thread Otavio Salvador
The WaRP Board is a Wearable Reference Plaform. The board features:

 - Freescale i.MX6 SoloLite processor with 512MB of RAM
 - Freescale FXOS8700CQ 6-axis Xtrinsic sensor
 - Freescale Kinetis KL16 MCU
 - Freescale Xtrinsic MMA955xL intelligent motion sensing platform

The board implements a hybrid architecture to address the evolving
needs of the wearables market. The platform consists of a main board
and an example daughtercard with the ability to add additional
daughtercards for different usage models.

For more information about the project, visit:

 http://www.warpboard.org/

Signed-off-by: Otavio Salvador ota...@ossystems.com.br
---
 arch/arm/boot/dts/Makefile|   3 +-
 arch/arm/boot/dts/imx6sl-warp.dts | 154 ++
 2 files changed, 156 insertions(+), 1 deletion(-)
 create mode 100644 arch/arm/boot/dts/imx6sl-warp.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index a1c776b..1b49d57 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -299,7 +299,8 @@ dtb-$(CONFIG_SOC_IMX6Q) += \
imx6q-wandboard.dtb \
imx6q-wandboard-revb1.dtb
 dtb-$(CONFIG_SOC_IMX6SL) += \
-   imx6sl-evk.dtb
+   imx6sl-evk.dtb \
+   imx6sl-warp.dtb
 dtb-$(CONFIG_SOC_IMX6SX) += \
imx6sx-sabreauto.dtb \
imx6sx-sdb.dtb
diff --git a/arch/arm/boot/dts/imx6sl-warp.dts 
b/arch/arm/boot/dts/imx6sl-warp.dts
new file mode 100644
index 000..dadb92f
--- /dev/null
+++ b/arch/arm/boot/dts/imx6sl-warp.dts
@@ -0,0 +1,154 @@
+/*
+ * Copyright 2014, 2015 O.S. Systems Software LTDA.
+ *
+ * The code contained herein is licensed under the GNU General Public
+ * License. You may obtain a copy of the GNU General Public License
+ * Version 2 or later at the following locations:
+ *
+ * http://www.opensource.org/licenses/gpl-license.html
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/dts-v1/;
+
+#include imx6sl.dtsi
+
+/ {
+   model = WaRP Board;
+   compatible = warp,imx6sl-warp, fsl,imx6sl;
+
+   memory {
+   reg = 0x8000 0x2000;
+   };
+
+   regulators {
+   compatible = simple-bus;
+   #address-cells = 1;
+   #size-cells = 0;
+
+   reg_usb_otg1_vbus: regulator@0 {
+   compatible = regulator-fixed;
+   reg = 0;
+   regulator-name = usb_otg1_vbus;
+   regulator-min-microvolt = 500;
+   regulator-max-microvolt = 500;
+   gpio = gpio4 0 0;
+   enable-active-high;
+   };
+
+   reg_usb_otg2_vbus: regulator@1 {
+   compatible = regulator-fixed;
+   reg = 1;
+   regulator-name = usb_otg2_vbus;
+   regulator-min-microvolt = 500;
+   regulator-max-microvolt = 500;
+   gpio = gpio4 2 0;
+   enable-active-high;
+   };
+
+   reg_1p8v: regulator@2 {
+   compatible = regulator-fixed;
+   reg = 2;
+   regulator-name = 1P8V;
+   regulator-min-microvolt = 180;
+   regulator-max-microvolt = 180;
+   };
+   };
+};
+
+uart1 {
+   pinctrl-names = default;
+   pinctrl-0 = pinctrl_uart1;
+   status = okay;
+};
+
+uart3 {
+   pinctrl-names = default;
+   pinctrl-0 = pinctrl_uart3;
+   status = okay;
+};
+
+usbotg1 {
+   vbus-supply = reg_usb_otg1_vbus;
+   dr_mode = host;
+   disable-over-current;
+   status = okay;
+};
+
+usbotg2 {
+   vbus-supply = reg_usb_otg2_vbus;
+   disable-over-current;
+   status = okay;
+};
+
+usdhc2 {
+   pinctrl-names = default, state_100mhz, state_200mhz;
+   pinctrl-0 = pinctrl_usdhc2;
+   pinctrl-1 = pinctrl_usdhc2_100mhz;
+   pinctrl-2 = pinctrl_usdhc2_200mhz;
+   non-removable;
+   status = okay;
+};
+
+iomuxc {
+   imx6sl-warp {
+   pinctrl_uart1: uart1grp {
+   fsl,pins = 
+   MX6SL_PAD_UART1_RXD__UART1_RX_DATA  0x41b0b1
+   MX6SL_PAD_UART1_TXD__UART1_TX_DATA  0x41b0b1
+   ;
+   };
+
+   pinctrl_uart3: uart3grp {
+   fsl,pins = 
+   MX6SL_PAD_AUD_RXC__UART3_RX_DATA0x41b0b1
+   MX6SL_PAD_AUD_RXC__UART3_TX_DATA0x41b0b1
+   ;
+   };
+
+   pinctrl_usdhc2: usdhc2grp {
+   fsl,pins = 
+   MX6SL_PAD_SD2_CMD__SD2_CMD  0x417059
+   MX6SL_PAD_SD2_CLK__SD2_CLK  0x410059

Re: The possible regression in kernel 4.8 - clk: imx: correct AV PLL rate formula

2016-10-11 Thread Otavio Salvador
On Tue, Oct 11, 2016 at 3:00 PM, Fabio Estevam <feste...@gmail.com> wrote:
> Hi Ken,
>
> On Tue, Oct 11, 2016 at 2:49 PM, Ken.Lin <ken@advantech.com> wrote:
>
>> With the patches applied, the pixel clock (14850 required for 
>> 1920x1080@60) is correct as we checked in kernel 4.7 and the actual 
>> measurement result looked good as we expected.
>> I think the patches should fix the issue.
>
> That's good news. Thanks for testing.
>
> Emil is working on a v3 version of the patch series.
>
> Emil,
>
> Please add Ken Lin on Cc when you submit v3.

And what will be done regarding 4.8? Is the faulty change to be
reverted or this patches will be backported?

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750


Re: [PATCH v2] ARM: dts: imx6qdl-nitrogen6x: Add SPI NOR partitions

2017-11-27 Thread Otavio Salvador
On Mon, Nov 27, 2017 at 8:17 AM, Gary Bisson
<gary.bis...@boundarydevices.com> wrote:
> Hi Otavio,
>
> On Sat, Nov 25, 2017 at 07:55:53AM -0200, Otavio Salvador wrote:
>> On Fri, Nov 24, 2017 at 3:00 PM, Otavio Salvador
>> <ota...@ossystems.com.br> wrote:
>> > This adds the partitions definition for the SPI NOR to provide
>> > backward compatibility with the documented[1] layout used with
>> > Boundary Devices BSP.
>> >
>> > 1. https://boundarydevices.com/boot-flash-access-linux/
>> >
>> > It exports to Linux:
>> >
>> >  mtd0: bootloader
>> >  mtd1: env
>> >  mtd2: splash
>> >
>> > Signed-off-by: Otavio Salvador <ota...@ossystems.com.br>
>>
>> After thinking a bit about Fabio's recommendation to use 'read-only'
>> to protect the partitions, I think it'd be better to use 'lock' so it
>> is still possible to write them on Linux but it requires a unlock
>> prior changing it.
>>
>> In my case, I am interested in being capable of upgrading the
>> bootloader from Linux.
>>
>> What people think?
>
> Agreed, I would rather have the lock option, especially for the splash
> and environment.

I will prepare a new patch using the lock option on the three
partitions so we allow the user to change them but knowing it may
break the system.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750


[PATCH v3] ARM: dts: imx6qdl-nitrogen6x: Add SPI NOR partitions

2017-11-27 Thread Otavio Salvador
This adds the partitions definition for the SPI NOR to provide
backward compatibility with the documented[1] layout used with
Boundary Devices BSP.

1. https://boundarydevices.com/boot-flash-access-linux/

It exports to Linux:

 mtd0: bootloader
 mtd1: env
 mtd2: splash

Signed-off-by: Otavio Salvador <ota...@ossystems.com.br>
---

Changes in v3:
 - use lock instead of read-only (Gary Bisson)

Changes in v2:
 - rework labels (Fabio Estevam)
 - add read-only flags (Fabio Estevam)

 arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi | 20 
 1 file changed, 20 insertions(+)

diff --git a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi 
b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
index 4bdf29169d2a..f855d802533e 100644
--- a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
@@ -276,6 +276,26 @@
compatible = "sst,sst25vf016b", "jedec,spi-nor";
spi-max-frequency = <2000>;
reg = <0>;
+   #address-cells = <1>;
+   #size-cells = <1>;
+
+   partition@0 {
+   label = "bootloader";
+   reg = <0x0 0xc>;
+   lock;
+   };
+
+   partition@c {
+   label = "env";
+   reg = <0xc 0x2000>;
+   lock;
+   };
+
+   partition@c2000 {
+   label = "splash";
+   reg = <0xc2000 0x13e000>;
+   lock;
+   };
};
 };
 
-- 
2.15.0



[PATCH v4] ARM: dts: imx6qdl-nitrogen6x: Add SPI NOR partitions

2017-11-28 Thread Otavio Salvador
This adds the partitions definition for the SPI NOR to provide
backward compatibility with the documented[1] layout used with
Boundary Devices BSP.

1. https://boundarydevices.com/boot-flash-access-linux/

It exports to Linux:

 mtd0: bootloader
 mtd1: env
 mtd2: splash

Signed-off-by: Otavio Salvador <ota...@ossystems.com.br>
---

Changes in v4:
 - drop lock flag

Changes in v3:
 - use lock instead of read-only (Gary Bisson)

Changes in v2:
 - rework labels (Fabio Estevam)
 - add read-only flags (Fabio Estevam)

 arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi | 17 +
 1 file changed, 17 insertions(+)

diff --git a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi 
b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
index 4bdf29169d2a..919b6b7619a4 100644
--- a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
@@ -276,6 +276,23 @@
compatible = "sst,sst25vf016b", "jedec,spi-nor";
spi-max-frequency = <2000>;
reg = <0>;
+   #address-cells = <1>;
+   #size-cells = <1>;
+
+   partition@0 {
+   label = "bootloader";
+   reg = <0x0 0xc>;
+   };
+
+   partition@c {
+   label = "env";
+   reg = <0xc 0x2000>;
+   };
+
+   partition@c2000 {
+   label = "splash";
+   reg = <0xc2000 0x13e000>;
+   };
};
 };
 
-- 
2.15.0



Re: [PATCH v3] ARM: dts: imx6qdl-nitrogen6x: Add SPI NOR partitions

2017-11-28 Thread Otavio Salvador
Hello Fabio,

On Mon, Nov 27, 2017 at 2:17 PM, Fabio Estevam <feste...@gmail.com> wrote:
> On Mon, Nov 27, 2017 at 11:31 AM, Otavio Salvador
> <ota...@ossystems.com.br> wrote:
>> This adds the partitions definition for the SPI NOR to provide
>> backward compatibility with the documented[1] layout used with
>> Boundary Devices BSP.
>>
>> 1. https://boundarydevices.com/boot-flash-access-linux/
>>
>> It exports to Linux:
>>
>>  mtd0: bootloader
>>  mtd1: env
>>  mtd2: splash
>>
>> Signed-off-by: Otavio Salvador <ota...@ossystems.com.br>
>
> Has this been tested? I mean, have you tested the locking mechanism is
> really working in this SPI NOR flash?

Yes, we tested it here using Linux 4.14 but didn't notice this SPI NOR
does not support the lock.

> As far as I can see the SPI locking mechanism does not need device
> tree properties.

Humm it is confusing, at least for me that am not used to the this. In
any case, I think for now it is better to include the partitions
without read-only and lock as it is convenient to have access to it
from Linux so we adhere the same partition layout used in Boundary's
Linux fork.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750


[PATCH] ARM: dts: imx6qdl-nitrogen6x: Add SPI NOR partitions

2017-11-24 Thread Otavio Salvador
This adds the partitions definition for the SPI NOR to provide
backward compatibility with the documented[1] layout used with
Boundary Devices BSP.

1. https://boundarydevices.com/boot-flash-access-linux/

It exports to Linux:

 mtd0: U-Boot
 mtd1: U-Boot Environment
 mtd2: Bootsplash

Signed-off-by: Otavio Salvador <ota...@ossystems.com.br>
---

 arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi | 17 +
 1 file changed, 17 insertions(+)

diff --git a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi 
b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
index 4bdf29169d2a..f8b267875e1c 100644
--- a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
@@ -276,6 +276,23 @@
compatible = "sst,sst25vf016b", "jedec,spi-nor";
spi-max-frequency = <2000>;
reg = <0>;
+   #address-cells = <1>;
+   #size-cells = <1>;
+
+   partition@0 {
+   label = "U-Boot";
+   reg = <0x0 0xc>;
+   };
+
+   partition@c {
+   label = "U-Boot Environment";
+   reg = <0xc 0x2000>;
+   };
+
+   partition@c2000 {
+   label = "Bootsplash";
+   reg = <0xc2000 0x13e000>;
+   };
};
 };
 
-- 
2.15.0



[PATCH v2] ARM: dts: imx6qdl-nitrogen6x: Add SPI NOR partitions

2017-11-24 Thread Otavio Salvador
This adds the partitions definition for the SPI NOR to provide
backward compatibility with the documented[1] layout used with
Boundary Devices BSP.

1. https://boundarydevices.com/boot-flash-access-linux/

It exports to Linux:

 mtd0: bootloader
 mtd1: env
 mtd2: splash

Signed-off-by: Otavio Salvador <ota...@ossystems.com.br>
---

Changes in v2:
 - rework labels (Fabio Estevam)
 - add read-only flags (Fabio Estevam)

 arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi | 20 
 1 file changed, 20 insertions(+)

diff --git a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi 
b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
index 4bdf29169d2a..28545412577a 100644
--- a/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-nitrogen6x.dtsi
@@ -276,6 +276,26 @@
compatible = "sst,sst25vf016b", "jedec,spi-nor";
spi-max-frequency = <2000>;
reg = <0>;
+   #address-cells = <1>;
+   #size-cells = <1>;
+
+   partition@0 {
+   label = "bootloader";
+   reg = <0x0 0xc>;
+   read-only;
+   };
+
+   partition@c {
+   label = "env";
+   reg = <0xc 0x2000>;
+   read-only;
+   };
+
+   partition@c2000 {
+   label = "splash";
+   reg = <0xc2000 0x13e000>;
+   read-only;
+   };
};
 };
 
-- 
2.15.0



Re: [PATCH v2] ARM: dts: imx6qdl-nitrogen6x: Add SPI NOR partitions

2017-11-25 Thread Otavio Salvador
On Fri, Nov 24, 2017 at 3:00 PM, Otavio Salvador
<ota...@ossystems.com.br> wrote:
> This adds the partitions definition for the SPI NOR to provide
> backward compatibility with the documented[1] layout used with
> Boundary Devices BSP.
>
> 1. https://boundarydevices.com/boot-flash-access-linux/
>
> It exports to Linux:
>
>  mtd0: bootloader
>  mtd1: env
>  mtd2: splash
>
> Signed-off-by: Otavio Salvador <ota...@ossystems.com.br>

After thinking a bit about Fabio's recommendation to use 'read-only'
to protect the partitions, I think it'd be better to use 'lock' so it
is still possible to write them on Linux but it requires a unlock
prior changing it.

In my case, I am interested in being capable of upgrading the
bootloader from Linux.

What people think?

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750


[PATCH] ARM: dts: rv1108-evb: enable eMMC support

2018-10-09 Thread Otavio Salvador
Enable eMMC support for rv1108 evaluation board.

Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/rv1108-evb.dts |  8 
 arch/arm/boot/dts/rv1108.dtsi| 29 +
 2 files changed, 37 insertions(+)

diff --git a/arch/arm/boot/dts/rv1108-evb.dts b/arch/arm/boot/dts/rv1108-evb.dts
index 70f0106d1252..f3c6f52c49e6 100644
--- a/arch/arm/boot/dts/rv1108-evb.dts
+++ b/arch/arm/boot/dts/rv1108-evb.dts
@@ -226,6 +226,14 @@
status = "okay";
 };
 
+ {
+   cap-mmc-highspeed;
+   supports-emmc;
+   non-removable;
+   num-slots = <1>;
+   status = "okay";
+};
+
  {
status = "okay";
 
diff --git a/arch/arm/boot/dts/rv1108.dtsi b/arch/arm/boot/dts/rv1108.dtsi
index 76ea24636feb..f14a733d85f6 100644
--- a/arch/arm/boot/dts/rv1108.dtsi
+++ b/arch/arm/boot/dts/rv1108.dtsi
@@ -772,6 +772,35 @@
};
};
 
+   emmc {
+   emmc_clk: emmc-clk {
+   rockchip,pins = <2 RK_PB6 RK_FUNC_1 
_pull_none_drv_8ma>;
+   };
+
+   emmc_cmd: emmc-cmd {
+   rockchip,pins = <2 RK_PB4 RK_FUNC_2 
_pull_up_drv_8ma>;
+   };
+
+   emmc_pwren: emmc-pwren {
+   rockchip,pins = <2 RK_PC2 RK_FUNC_2 
_pull_none>;
+   };
+
+   emmc_bus1: emmc-bus1 {
+   rockchip,pins = <2 RK_PA0 RK_FUNC_2 
_pull_up_drv_8ma>;
+   };
+
+   emmc_bus8: emmc-bus8 {
+   rockchip,pins = <2 RK_PA0 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA1 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA2 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA3 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA4 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA5 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA6 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA7 RK_FUNC_2 
_pull_up_drv_8ma>;
+   };
+   };
+
sdmmc {
sdmmc_clk: sdmmc-clk {
rockchip,pins = <3 RK_PC4 RK_FUNC_1 
_pull_none_drv_4ma>;
-- 
2.19.0



Re: [PATCH v2 0/9] Improvements for i.MX7D PICO SoM and its baseboards

2018-12-07 Thread Otavio Salvador
Hello Shawn,

On Thu, Dec 6, 2018 at 8:44 AM Otavio Salvador  wrote:
> On Thu, Dec 6, 2018 at 8:09 AM Otavio Salvador  
> wrote:
> > This patchset rework the imx7d-pico SoM, its Pi baseboard
> > and add the Hobbit baseboard support as well.
> >
> > Changes in v2:
> > - replace fsl,uart-has-rtscts with uart-has-rtscts
> >
> > Fabio Estevam (8):
> >   ARM: dts: imx7d-pico: Do not harcode the memory size
> >   ARM: dts: imx7d-pico: Switch to SPDX identifier
> >   ARM: dts: imx7d-pico-pi: Move SoM related part to imx7d-pico.dtsi
>
> I did the rebase; one thing worth mentioning is that I have "ARM: dts:
> imx7d-pico: Describe the Wifi clock" which is in your fixes tree.

Do you wish me to resent this now that the "ARM: dts: imx7d-pico:
Describe the Wifi clock" is on linux-next? If so I can rebase and
resend. Just let me know how to make it more convenient for you,
please?

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854  Mobile: +1 (347) 903-9750


[PATCH 4/5] ARM: dts: imx6ul-pico-hobbit: Extend peripherals support

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

This adds following peripherals support:

 - ADC
 - GPIO LED
 - GPIOs

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx6ul-pico-hobbit.dts | 30 
 1 file changed, 30 insertions(+)

diff --git a/arch/arm/boot/dts/imx6ul-pico-hobbit.dts 
b/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
index 8656ccbb5a06..f2dd6945e98c 100644
--- a/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
+++ b/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
@@ -14,6 +14,8 @@
 
leds {
compatible = "gpio-leds";
+   pinctrl-names = "default";
+   pinctrl-0 = <_gpio_leds>;
 
led {
label = "gpio-led";
@@ -58,6 +60,12 @@
  {
status = "okay";
 
+   adc081c: adc@50 {
+   compatible = "ti,adc081c";
+   reg = <0x50>;
+   vref-supply = <_3p3v>;
+   };
+
polytouch: touchscreen@38 {
compatible = "edt,edt-ft5x06";
reg = <0x38>;
@@ -68,3 +76,25 @@
touchscreen-size-y = <480>;
};
 };
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_hog>;
+
+   pinctrl_hog: hoggrp {
+   fsl,pins = <
+   MX6UL_PAD_CSI_VSYNC__GPIO4_IO19 0x10b0
+   MX6UL_PAD_CSI_DATA00__GPIO4_IO210x10b0
+   MX6UL_PAD_CSI_DATA01__GPIO4_IO220x10b0
+   MX6UL_PAD_CSI_DATA02__GPIO4_IO230x10b0
+   MX6UL_PAD_UART1_CTS_B__GPIO1_IO18   0x10b0
+   MX6UL_PAD_SNVS_TAMPER2__GPIO5_IO02  0x10b0
+   >;
+   };
+
+   pinctrl_gpio_leds: gpioledsgrp {
+   fsl,pins = <
+   MX6UL_PAD_UART4_RX_DATA__GPIO1_IO29 0x10b0
+   >;
+   };
+};
-- 
2.19.2



[PATCH 5/5] ARM: dts: imx6ul-pico: Add the imx6ul-pico-pi variant

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

The imx6ul-pico-pi contains a imx6ul-pico SoM and a pi baseboard:
https://www.technexion.com/products/pico-baseboards/detail/PICO-PI

Add support for it.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/Makefile   |  1 +
 arch/arm/boot/dts/imx6ul-pico-pi.dts | 97 
 arch/arm/boot/dts/imx6ul-pico.dtsi   | 32 -
 3 files changed, 98 insertions(+), 32 deletions(-)
 create mode 100644 arch/arm/boot/dts/imx6ul-pico-pi.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 12a3cfb7d280..f26591295497 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -557,6 +557,7 @@ dtb-$(CONFIG_SOC_IMX6UL) += \
imx6ul-liteboard.dtb \
imx6ul-opos6uldev.dtb \
imx6ul-pico-hobbit.dtb \
+   imx6ul-pico-pi.dtb \
imx6ul-tx6ul-0010.dtb \
imx6ul-tx6ul-0011.dtb \
imx6ul-tx6ul-mainboard.dtb \
diff --git a/arch/arm/boot/dts/imx6ul-pico-pi.dts 
b/arch/arm/boot/dts/imx6ul-pico-pi.dts
new file mode 100644
index ..de07357b27fc
--- /dev/null
+++ b/arch/arm/boot/dts/imx6ul-pico-pi.dts
@@ -0,0 +1,97 @@
+// SPDX-License-Identifier: (GPL-2.0 OR MIT)
+//
+// Copyright 2015 Technexion Ltd.
+//
+// Author: Wig Cheng  
+//Richard Hu 
+//Tapani Utriainen 
+/dts-v1/;
+
+#include "imx6ul-pico.dtsi"
+/ {
+   model = "TechNexion PICO-IMX6UL and PI baseboard";
+   compatible = "technexion,imx6ul-pico-pi", "fsl,imx6ul";
+
+   leds {
+   compatible = "gpio-leds";
+   pinctrl-names = "default";
+   pinctrl-0 = <_gpio_leds>;
+
+   led {
+   label = "gpio-led";
+   gpios = < 20 GPIO_ACTIVE_HIGH>;
+   };
+   };
+
+   sound {
+   compatible = "fsl,imx-audio-sgtl5000";
+   model = "imx6ul-sgtl5000";
+   audio-cpu = <>;
+   audio-codec = <>;
+   audio-routing =
+   "LINE_IN", "Line In Jack",
+   "MIC_IN", "Mic Jack",
+   "Mic Jack", "Mic Bias",
+   "Headphone Jack", "HP_OUT";
+   };
+
+   sys_mclk: clock-sys-mclk {
+   compatible = "fixed-clock";
+   #clock-cells = <0>;
+   clock-frequency = <24576000>;
+   };
+};
+
+ {
+   clock_frequency = <10>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_i2c2>;
+   status = "okay";
+
+   sgtl5000: codec@a {
+   reg = <0x0a>;
+   compatible = "fsl,sgtl5000";
+   clocks = <_mclk>;
+   VDDA-supply = <_2p5v>;
+   VDDIO-supply = <_3p3v>;
+   };
+};
+
+ {
+   clock_frequency = <10>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_i2c3>;
+   status = "okay";
+
+   polytouch: touchscreen@38 {
+   compatible = "edt,edt-ft5x06";
+   reg = <0x38>;
+   interrupt-parent = <>;
+   interrupts = <29 IRQ_TYPE_EDGE_FALLING>;
+   reset-gpios = < 24 GPIO_ACTIVE_LOW>;
+   touchscreen-size-x = <800>;
+   touchscreen-size-y = <480>;
+   };
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_hog>;
+
+   pinctrl_hog: hoggrp {
+   fsl,pins = <
+   MX6UL_PAD_CSI_VSYNC__GPIO4_IO19 0x10b0
+   MX6UL_PAD_CSI_DATA00__GPIO4_IO210x10b0
+   MX6UL_PAD_CSI_DATA01__GPIO4_IO220x10b0
+   MX6UL_PAD_CSI_DATA02__GPIO4_IO230x10b0
+   MX6UL_PAD_UART1_CTS_B__GPIO1_IO18   0x10b0
+   MX6UL_PAD_SNVS_TAMPER2__GPIO5_IO02  0x10b0
+   >;
+   };
+
+   pinctrl_gpio_leds: gpioledsgrp {
+   fsl,pins = <
+   MX6UL_PAD_CSI_HSYNC__GPIO4_IO20 0x10b0
+   >;
+   };
+};
diff --git a/arch/arm/boot/dts/imx6ul-pico.dtsi 
b/arch/arm/boot/dts/imx6ul-pico.dtsi
index 89269955440b..de9f83189ba8 100644
--- a/arch/arm/boot/dts/imx6ul-pico.dtsi
+++ b/arch/arm/boot/dts/imx6ul-pico.dtsi
@@ -72,24 +72,6 @@
regulator-max-microvolt = <330>;
startup-delay-us = <20>;
};
-
-   sound {
-   compatible = "fsl,imx-audio-sgtl5000";
-   model = "imx6ul-sgtl5000";
-   audio-cpu = <>;
-   

[PATCH 1/5] ARM: dts: imx6ul-pico-hobbit: Switch to SPDX identifier

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

Adopt the SPDX license identifier headers to ease license compliance
management.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx6ul-pico-hobbit.dts | 52 
 1 file changed, 7 insertions(+), 45 deletions(-)

diff --git a/arch/arm/boot/dts/imx6ul-pico-hobbit.dts 
b/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
index 797262d2f27f..1bc4fb4b4841 100644
--- a/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
+++ b/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
@@ -1,48 +1,10 @@
-/*
- * Copyright 2015 Technexion Ltd.
- *
- * Author: Wig Cheng  
- *Richard Hu 
- *Tapani Utriainen 
- *
- * This file is dual-licensed: you can use it either under the terms
- * of the GPL or the X11 license, at your option. Note that this dual
- * licensing only applies to this file, and not this project as a
- * whole.
- *
- *  a) This file is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License
- * version 2 as published by the Free Software Foundation.
- *
- * This file is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * Or, alternatively,
- *
- *  b) Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use,
- * copy, modify, merge, publish, distribute, sublicense, and/or
- * sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following
- * conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
- * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
- * OTHER DEALINGS IN THE SOFTWARE.
- */
-
+// SPDX-License-Identifier: (GPL-2.0 OR MIT)
+//
+// Copyright 2015 Technexion Ltd.
+//
+// Author: Wig Cheng  
+//Richard Hu 
+//Tapani Utriainen 
 /dts-v1/;
 
 #include "imx6ul.dtsi"
-- 
2.19.2



[PATCH 2/5] ARM: dts: imx6ul-pico-hobbit: Move SoM related part to imx6ul-pico.dtsi

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

imx6ul-pico-hobbit board contains:

- One SoM board (imx6ul pico)
- One base board (hobbit).

In order to make it easier for adding support for other board variants,
move the commom SoM part to the imx6ul-pico.dtsi file.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx6ul-pico-hobbit.dts | 479 +-
 arch/arm/boot/dts/imx6ul-pico.dtsi   | 493 +++
 2 files changed, 511 insertions(+), 461 deletions(-)
 create mode 100644 arch/arm/boot/dts/imx6ul-pico.dtsi

diff --git a/arch/arm/boot/dts/imx6ul-pico-hobbit.dts 
b/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
index 1bc4fb4b4841..3cc04dd6f341 100644
--- a/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
+++ b/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
@@ -7,80 +7,25 @@
 //Tapani Utriainen 
 /dts-v1/;
 
-#include "imx6ul.dtsi"
-
+#include "imx6ul-pico.dtsi"
 / {
-   model = "Technexion Pico i.MX6UL Board";
+   model = "TechNexion PICO-IMX6UL and HOBBIT baseboard";
compatible = "technexion,imx6ul-pico-hobbit", "fsl,imx6ul";
 
-   /* Will be filled by the bootloader */
-   memory@8000 {
-   device_type = "memory";
-   reg = <0x8000 0>;
-   };
-
-   chosen {
-   stdout-path = 
-   };
-
-   backlight {
-   compatible = "pwm-backlight";
-   pwms = < 0 500>;
-   brightness-levels = <0 4 8 16 32 64 128 255>;
-   default-brightness-level = <6>;
-   status = "okay";
-   };
-
-   reg_2p5v: regulator-2p5v {
-   compatible = "regulator-fixed";
-   regulator-name = "2P5V";
-   regulator-min-microvolt = <250>;
-   regulator-max-microvolt = <250>;
-   };
-
-   reg_3p3v: regulator-3p3v {
-   compatible = "regulator-fixed";
-   regulator-name = "3P3V";
-   regulator-min-microvolt = <330>;
-   regulator-max-microvolt = <330>;
-   };
-
-   reg_sd1_vmmc: regulator-sd1-vmmc {
-   compatible = "regulator-fixed";
-   regulator-name = "VSD_3V3";
-   regulator-min-microvolt = <330>;
-   regulator-max-microvolt = <330>;
-   gpio = < 9 GPIO_ACTIVE_HIGH>;
-   enable-active-high;
-   };
-
-   reg_usb_otg_vbus: regulator-usb-otg-vbus {
-   compatible = "regulator-fixed";
-   pinctrl-names = "default";
-   pinctrl-0 = <_usb_otg1>;
-   regulator-name = "usb_otg_vbus";
-   regulator-min-microvolt = <500>;
-   regulator-max-microvolt = <500>;
-   gpio = < 6 0>;
-   };
+   leds {
+   compatible = "gpio-leds";
 
-   reg_brcm: regulator-brcm {
-   compatible = "regulator-fixed";
-   enable-active-high;
-   gpio = < 8 GPIO_ACTIVE_HIGH>;
-   pinctrl-names = "default";
-   pinctrl-0 = <_brcm_reg>;
-   regulator-name = "brcm_reg";
-   regulator-min-microvolt = <330>;
-   regulator-max-microvolt = <330>;
-   startup-delay-us = <20>;
+   hobbitled {
+   label = "hobbitled";
+   gpios = < 29 GPIO_ACTIVE_LOW>;
+   };
};
 
sound {
compatible = "fsl,imx-audio-sgtl5000";
model = "imx6ul-sgtl5000";
audio-cpu = <>;
-   audio-codec = <>;
+   audio-codec = <>;
audio-routing =
"LINE_IN", "Line In Jack",
"MIC_IN", "Mic Jack",
@@ -93,92 +38,6 @@
#clock-cells = <0>;
clock-frequency = <24576000>;
};
-
-   leds {
-   compatible = "gpio-leds";
-
-   hobbitled {
-   label = "hobbitled";
-   gpios = < 29 GPIO_ACTIVE_LOW>;
-   };
-   };
-};
-
- {
-   pinctrl-names = "default";
-   pinctrl-0 = <_flexcan1>;
-   status = "okay";
-};
-
- {
-   pinctrl-names = "default";
-   pinctrl-0 = <_flexcan2>;
-   status = "okay";
-};
-
- {
-   assigned-clocks = < IMX6UL_CLK_PLL4_AUDIO_DIV>;
-   assigned-clock-rates = <786432000>;
-};
-
- {
-   

[PATCH 3/5] ARM: dts: imx6ul-pico-hobbit: Make the child led nodes standard

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

Use the same child led node and label name as used in the
imx7d-pico-hobbit board.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx6ul-pico-hobbit.dts | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/imx6ul-pico-hobbit.dts 
b/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
index 3cc04dd6f341..8656ccbb5a06 100644
--- a/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
+++ b/arch/arm/boot/dts/imx6ul-pico-hobbit.dts
@@ -15,8 +15,8 @@
leds {
compatible = "gpio-leds";
 
-   hobbitled {
-   label = "hobbitled";
+   led {
+   label = "gpio-led";
gpios = < 29 GPIO_ACTIVE_LOW>;
};
};
-- 
2.19.2



[PATCH 0/5] Improvements for i.MX6UL PICO SoM and its baseboards

2018-12-02 Thread Otavio Salvador
This patchset rework the imx6ul-pico SoM, its Hobbit baseboard
and add the Pi baseboard support as well.


Fabio Estevam (5):
  ARM: dts: imx6ul-pico-hobbit: Switch to SPDX identifier
  ARM: dts: imx6ul-pico-hobbit: Move SoM related part to
imx6ul-pico.dtsi
  ARM: dts: imx6ul-pico-hobbit: Make the child led nodes standard
  ARM: dts: imx6ul-pico-hobbit: Extend peripherals support
  ARM: dts: imx6ul-pico: Add the imx6ul-pico-pi variant

 arch/arm/boot/dts/Makefile   |   1 +
 arch/arm/boot/dts/imx6ul-pico-hobbit.dts | 535 ++-
 arch/arm/boot/dts/imx6ul-pico-pi.dts |  97 
 arch/arm/boot/dts/imx6ul-pico.dtsi   | 461 +++
 4 files changed, 601 insertions(+), 493 deletions(-)
 create mode 100644 arch/arm/boot/dts/imx6ul-pico-pi.dts
 create mode 100644 arch/arm/boot/dts/imx6ul-pico.dtsi

-- 
2.19.2



[PATCH 7/9] ARM: dts: imx7d-pico: Extend peripherals support

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

This extends the peripherals supported by the imx7d-pico.dtsi. It
adds:

 - I2C2
 - Flexcan (flexcan1 and flexcan2 ports)
 - USDHC1
 - UART (6 and 7 ports)
 - PWM (4 ports)
 - eCSPI3

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx7d-pico.dtsi | 183 ++
 1 file changed, 183 insertions(+)

diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index 417f034fb354..6c7581336f96 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -78,6 +78,13 @@
assigned-clock-rates = <0>, <32768>;
 };
 
+ {
+   cs-gpios = < 11 GPIO_ACTIVE_LOW>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_ecspi3>;
+   status = "okay";
+};
+
  {
pinctrl-names = "default";
pinctrl-0 = <_enet1>;
@@ -103,6 +110,18 @@
};
 };
 
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_can1>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_can2>;
+   status = "okay";
+};
+
  {
clock-frequency = <10>;
pinctrl-names = "default";
@@ -110,6 +129,12 @@
status = "okay";
 };
 
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_i2c2>;
+   status = "okay";
+};
+
  {
pinctrl-names = "default";
pinctrl-0 = <_i2c4>;
@@ -215,6 +240,29 @@
status = "okay";
 };
 
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pwm1>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pwm2>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pwm3>;
+   status = "okay";
+};
+
+ { /* Backlight */
+   status = "okay";
+};
+
  {
pinctrl-names = "default";
pinctrl-0 = <_uart5>;
@@ -223,6 +271,24 @@
status = "okay";
 };
 
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_uart6>;
+   assigned-clocks = < IMX7D_UART6_ROOT_SRC>;
+   assigned-clock-parents = < IMX7D_OSC_24M_CLK>;
+   fsl,uart-has-rtscts;
+   status = "okay";
+};
+
+ { /* Bluetooth */
+   pinctrl-names = "default";
+   pinctrl-0 = <_uart7>;
+   assigned-clocks = < IMX7D_UART7_ROOT_SRC>;
+   assigned-clock-parents = < IMX7D_PLL_SYS_MAIN_240M_CLK>;
+   fsl,uart-has-rtscts;
+   status = "okay";
+};
+
  {
vbus-supply = <_usb_otg1_vbus>;
status = "okay";
@@ -234,6 +300,21 @@
status = "okay";
 };
 
+ {
+   pinctrl-names = "default", "state_100mhz", "state_200mhz";
+   pinctrl-0 = <_usdhc1>;
+   pinctrl-1 = <_usdhc1_100mhz>;
+   pinctrl-2 = <_usdhc1_200mhz>;
+   cd-gpios = < 0 GPIO_ACTIVE_LOW>;
+   bus-width = <4>;
+   tuning-step = <2>;
+   vmmc-supply = <_3p3v>;
+   wakeup-source;
+   no-1-8-v;
+   keep-power-in-suspend;
+   status = "okay";
+};
+
  { /* Wifi SDIO */
pinctrl-names = "default";
pinctrl-0 = <_usdhc2 _wifi_clk>;
@@ -268,6 +349,15 @@
 };
 
  {
+   pinctrl_ecspi3: ecspi3grp {
+   fsl,pins = <
+   MX7D_PAD_I2C1_SCL__ECSPI3_MISO  0x2
+   MX7D_PAD_I2C1_SDA__ECSPI3_MOSI  0x2
+   MX7D_PAD_I2C2_SCL__ECSPI3_SCLK  0x2
+   MX7D_PAD_I2C2_SDA__GPIO4_IO11   0x14
+   >;
+   };
+
pinctrl_i2c1: i2c1grp {
fsl,pins = <
MX7D_PAD_UART1_TX_DATA__I2C1_SDA0x407f
@@ -275,6 +365,13 @@
>;
};
 
+   pinctrl_i2c2: i2c2grp {
+   fsl,pins = <
+   MX7D_PAD_UART2_TX_DATA__I2C2_SDA0x407f
+   MX7D_PAD_UART2_RX_DATA__I2C2_SCL0x407f
+   >;
+   };
+
pinctrl_enet1: enet1grp {
fsl,pins = <
MX7D_PAD_SD2_CD_B__ENET1_MDIO   0x3
@@ -295,6 +392,20 @@
>;
};
 
+   pinctrl_can1: can1frp {
+   fsl,pins = <
+   MX7D_PAD_SAI1_RX_DATA__FLEXCAN1_RX  0x59
+   MX7D_PAD_SAI1_TX_BCLK__FLEXCAN1_TX  0x59
+   >;
+   };
+
+   pinctrl_can2: can2frp {
+   fsl,pins = <
+   MX7D_PAD_SAI1_TX_SYNC__FLEXCAN2_RX  0x59
+ 

[PATCH 9/9] ARM: dts: imx7d-pico: Add the imx7d-pico-hobbit variant

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

The imx7d-pico-hobbit contains a imx7d-pico SoM and a hobbit baseboard.

Add support for it.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/Makefile  |   1 +
 arch/arm/boot/dts/imx7d-pico-hobbit.dts | 105 
 2 files changed, 106 insertions(+)
 create mode 100644 arch/arm/boot/dts/imx7d-pico-hobbit.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index b0e966d625b9..12a3cfb7d280 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -569,6 +569,7 @@ dtb-$(CONFIG_SOC_IMX7D) += \
imx7d-colibri-emmc-eval-v3.dtb \
imx7d-colibri-eval-v3.dtb \
imx7d-nitrogen7.dtb \
+   imx7d-pico-hobbit.dtb \
imx7d-pico-pi.dtb \
imx7d-sbc-imx7.dtb \
imx7d-sdb.dtb \
diff --git a/arch/arm/boot/dts/imx7d-pico-hobbit.dts 
b/arch/arm/boot/dts/imx7d-pico-hobbit.dts
new file mode 100644
index ..7b2198a9372c
--- /dev/null
+++ b/arch/arm/boot/dts/imx7d-pico-hobbit.dts
@@ -0,0 +1,105 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+//
+// Copyright 2017 NXP
+
+#include "imx7d-pico.dtsi"
+
+/ {
+   model = "TechNexion PICO-IMX7D Board using Hobbit baseboard";
+   compatible = "technexion,imx7d-pico-hobbit", "fsl,imx7d";
+
+   leds {
+   compatible = "gpio-leds";
+   pinctrl-names = "default";
+   pinctrl-0 = <_gpio_leds>;
+
+   led {
+   label = "gpio-led";
+   gpios = < 13 GPIO_ACTIVE_HIGH>;
+   };
+   };
+
+   sound {
+   compatible = "simple-audio-card";
+   simple-audio-card,name = "imx7-sgtl5000";
+   simple-audio-card,format = "i2s";
+   simple-audio-card,bitclock-master = <_master>;
+   simple-audio-card,frame-master = <_master>;
+   simple-audio-card,cpu {
+   sound-dai = <>;
+   };
+
+   dailink_master: simple-audio-card,codec {
+   sound-dai = <>;
+   clocks = < IMX7D_AUDIO_MCLK_ROOT_CLK>;
+   };
+   };
+};
+
+ {
+   sgtl5000: codec@a {
+   #sound-dai-cells = <0>;
+   reg = <0x0a>;
+   compatible = "fsl,sgtl5000";
+   clocks = < IMX7D_AUDIO_MCLK_ROOT_CLK>;
+   VDDA-supply = <_2p5v>;
+   VDDIO-supply = <_vref_1v8>;
+   };
+};
+
+ {
+   status = "okay";
+
+   adc081c: adc@50 {
+   compatible = "ti,adc081c";
+   reg = <0x50>;
+   vref-supply = <_3p3v>;
+   };
+};
+
+ {
+   ads7846@0 {
+   reg = <0>;
+   compatible = "ti,ads7846";
+   interrupt-parent = <>;
+   interrupts = <7 0>;
+   spi-max-frequency = <100>;
+   pendown-gpio = < 7 0>;
+   vcc-supply = <_3p3v>;
+   ti,x-min = /bits/ 16 <0>;
+   ti,x-max = /bits/ 16 <4095>;
+   ti,y-min = /bits/ 16 <0>;
+   ti,y-max = /bits/ 16 <4095>;
+   ti,pressure-max = /bits/ 16 <1024>;
+   ti,x-plate-ohms = /bits/ 16 <90>;
+   ti,y-plate-ohms = /bits/ 16 <90>;
+   ti,debounce-max = /bits/ 16 <70>;
+   ti,debounce-tol = /bits/ 16 <3>;
+   ti,debounce-rep = /bits/ 16 <2>;
+   ti,settle-delay-usec = /bits/ 16 <150>;
+   wakeup-source;
+   };
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_hog>;
+
+   pinctrl_hog: hoggrp {
+   fsl,pins = <
+   MX7D_PAD_EPDC_DATA00__GPIO2_IO0 0x14
+   MX7D_PAD_EPDC_DATA01__GPIO2_IO1 0x14
+   MX7D_PAD_EPDC_DATA02__GPIO2_IO2 0x14
+   MX7D_PAD_EPDC_DATA03__GPIO2_IO3 0x14
+   MX7D_PAD_EPDC_DATA05__GPIO2_IO5 0x14
+   MX7D_PAD_EPDC_DATA12__GPIO2_IO120x14
+   MX7D_PAD_EPDC_DATA07__GPIO2_IO7 0x14
+   >;
+   };
+
+   pinctrl_gpio_leds: gpioledsgrp {
+   fsl,pins = <
+   MX7D_PAD_EPDC_DATA13__GPIO2_IO130x14
+   >;
+   };
+};
-- 
2.19.2



[PATCH 4/9] ARM: dts: imx7d-pico: Pass the USBOTG1_PWR pinctrl

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

Pass the USBOTG1_PWR pinctrl description in the USBOTG GPIO
controlled regulator.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx7d-pico.dtsi | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index 7319e2ecec5c..cb30bded1e4a 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -41,6 +41,8 @@
};
 
reg_usb_otg1_vbus: regulator-usb-otg1-vbus {
+   pinctrl-names = "default";
+   pinctrl-0 = <_usbotg1_pwr>;
compatible = "regulator-fixed";
regulator-name = "usb_otg1_vbus";
regulator-min-microvolt = <500>;
-- 
2.19.2



[PATCH 8/9] ARM: dts: imx7d-pico-pi: Extend peripherals support

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

This adds following peripherals for the imx7d-pico-pi as:

 - LED
 - Touchscreen
 - GPIO

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx7d-pico-pi.dts | 56 +
 1 file changed, 56 insertions(+)

diff --git a/arch/arm/boot/dts/imx7d-pico-pi.dts 
b/arch/arm/boot/dts/imx7d-pico-pi.dts
index 039c17066fe0..70bea95c06d8 100644
--- a/arch/arm/boot/dts/imx7d-pico-pi.dts
+++ b/arch/arm/boot/dts/imx7d-pico-pi.dts
@@ -8,6 +8,17 @@
model = "TechNexion PICO-IMX7D Board and PI baseboard";
compatible = "technexion,imx7d-pico-pi", "fsl,imx7d";
 
+   leds {
+   compatible = "gpio-leds";
+   pinctrl-names = "default";
+   pinctrl-0 = <_gpio_leds>;
+
+   led {
+   label = "gpio-led";
+   gpios = < 6 GPIO_ACTIVE_HIGH>;
+   };
+   };
+
sound {
compatible = "simple-audio-card";
simple-audio-card,name = "imx7-sgtl5000";
@@ -35,3 +46,48 @@
VDDIO-supply = <_vref_1v8>;
};
 };
+
+ {
+   polytouch: touchscreen@38 {
+   compatible = "edt,edt-ft5x06";
+   reg = <0x38>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_touchscreen>;
+   interrupt-parent = <>;
+   interrupts = <13 IRQ_TYPE_EDGE_FALLING>;
+   reset-gpios = < 4 GPIO_ACTIVE_LOW>;
+   touchscreen-size-x = <800>;
+   touchscreen-size-y = <480>;
+   };
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_hog>;
+
+   pinctrl_hog: hoggrp {
+   fsl,pins = <
+   MX7D_PAD_EPDC_DATA00__GPIO2_IO0 0x14
+   MX7D_PAD_EPDC_DATA01__GPIO2_IO1 0x14
+   MX7D_PAD_EPDC_DATA02__GPIO2_IO2 0x14
+   MX7D_PAD_EPDC_DATA03__GPIO2_IO3 0x14
+   MX7D_PAD_EPDC_DATA05__GPIO2_IO5 0x14
+   MX7D_PAD_EPDC_DATA12__GPIO2_IO120x14
+   MX7D_PAD_EPDC_DATA07__GPIO2_IO7 0x14
+   >;
+   };
+
+   pinctrl_gpio_leds: gpioledsgrp {
+   fsl,pins = <
+   MX7D_PAD_EPDC_DATA06__GPIO2_IO6 0x14
+   >;
+   };
+
+   pinctrl_touchscreen: touchscreengrp {
+   fsl,pins = <
+   MX7D_PAD_EPDC_DATA04__GPIO2_IO4 0x14
+   MX7D_PAD_EPDC_DATA13__GPIO2_IO130x14
+   >;
+   };
+
+};
-- 
2.19.2



[PATCH 6/9] ARM: dts: imx7d-pico: Improve WiFi regulator name

2018-12-02 Thread Otavio Salvador
There are different models of WiFi being used in the SoM and the
handle name was too restrictive. This reworks it to a more generic and
meaningful name.

Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx7d-pico.dtsi | 10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index 35791a1adabf..417f034fb354 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -13,11 +13,11 @@
reg = <0x8000 0>;
};
 
-   reg_ap6212: regulator-ap6212 {
+   reg_wlreg_on: regulator-wlreg_on {
compatible = "regulator-fixed";
pinctrl-names = "default";
-   pinctrl-0 = <_reg_ap6212>;
-   regulator-name = "AP6212";
+   pinctrl-0 = <_reg_wlreg_on>;
+   regulator-name = "wlreg_on";
regulator-min-microvolt = <330>;
regulator-max-microvolt = <330>;
gpio = < 16 GPIO_ACTIVE_HIGH>;
@@ -241,7 +241,7 @@
non-removable;
keep-power-in-suspend;
wakeup-source;
-   vmmc-supply = <_ap6212>;
+   vmmc-supply = <_wlreg_on>;
mmc-pwrseq = <_pwrseq>;
status = "okay";
 };
@@ -302,7 +302,7 @@
>;
};
 
-   pinctrl_reg_ap6212: regap6212grp {
+   pinctrl_reg_wlreg_on: regregongrp {
fsl,pins = <
MX7D_PAD_ECSPI1_SCLK__GPIO4_IO160x59
>;
-- 
2.19.2



[PATCH 5/9] ARM: dts: imx7d-pico: Pass the Ethernet PHY reset GPIO

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

Pass the "phy-reset-gpios" property in order to describe the GPIO
that performs the Ethernet PHY reset.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx7d-pico.dtsi | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index cb30bded1e4a..35791a1adabf 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -88,6 +88,7 @@
phy-mode = "rgmii";
phy-handle = <>;
fsl,magic-packet;
+   phy-reset-gpios = < 11 GPIO_ACTIVE_LOW>;
status = "okay";
 
mdio {
@@ -290,6 +291,7 @@
MX7D_PAD_ENET1_RGMII_RD2__ENET1_RGMII_RD2   0x1
MX7D_PAD_ENET1_RGMII_RD3__ENET1_RGMII_RD3   0x1
MX7D_PAD_ENET1_RGMII_RX_CTL__ENET1_RGMII_RX_CTL 0x1
+   MX7D_PAD_SD3_RESET_B__GPIO6_IO110x1  /* 
Ethernet reset */
>;
};
 
-- 
2.19.2



[PATCH 3/9] ARM: dts: imx7d-pico-pi: Move SoM related part to imx7d-pico.dtsi

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

imx7d-pico-pi board contains:

- One SoM board (imx7d pico)
- One base board (pi).

In order to make it easier for adding support for other board variants,
move the commom SoM part to the imx7d-pico.dtsi file.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx7d-pico-pi.dts | 116 ++--
 arch/arm/boot/dts/imx7d-pico.dtsi   | 111 +-
 2 files changed, 113 insertions(+), 114 deletions(-)

diff --git a/arch/arm/boot/dts/imx7d-pico-pi.dts 
b/arch/arm/boot/dts/imx7d-pico-pi.dts
index 33951f4c7f41..039c17066fe0 100644
--- a/arch/arm/boot/dts/imx7d-pico-pi.dts
+++ b/arch/arm/boot/dts/imx7d-pico-pi.dts
@@ -5,6 +5,9 @@
 #include "imx7d-pico.dtsi"
 
 / {
+   model = "TechNexion PICO-IMX7D Board and PI baseboard";
+   compatible = "technexion,imx7d-pico-pi", "fsl,imx7d";
+
sound {
compatible = "simple-audio-card";
simple-audio-card,name = "imx7-sgtl5000";
@@ -16,43 +19,14 @@
};
 
dailink_master: simple-audio-card,codec {
-   sound-dai = <>;
+   sound-dai = <>;
clocks = < IMX7D_AUDIO_MCLK_ROOT_CLK>;
};
};
 };
 
- {
-   pinctrl-names = "default";
-   pinctrl-0 = <_enet1>;
-   assigned-clocks = < IMX7D_ENET1_TIME_ROOT_SRC>,
- < IMX7D_ENET1_TIME_ROOT_CLK>;
-   assigned-clock-parents = < IMX7D_PLL_ENET_MAIN_100M_CLK>;
-   assigned-clock-rates = <0>, <1>;
-   phy-mode = "rgmii";
-   phy-handle = <>;
-   fsl,magic-packet;
-   status = "okay";
-
-   mdio {
-   #address-cells = <1>;
-   #size-cells = <0>;
-
-   ethphy0: ethernet-phy@1 {
-   compatible = "ethernet-phy-ieee802.3-c22";
-   reg = <1>;
-   status = "okay";
-   };
-   };
-};
-
  {
-   clock-frequency = <10>;
-   pinctrl-names = "default";
-   pinctrl-0 = <_i2c1>;
-   status = "okay";
-
-   codec: sgtl5000@a {
+   sgtl5000: codec@a {
#sound-dai-cells = <0>;
reg = <0x0a>;
compatible = "fsl,sgtl5000";
@@ -61,83 +35,3 @@
VDDIO-supply = <_vref_1v8>;
};
 };
-
-
- {
-   pinctrl-names = "default";
-   pinctrl-0 = <_sai1>;
-   assigned-clocks = < IMX7D_SAI1_ROOT_SRC>,
- < IMX7D_SAI1_ROOT_CLK>;
-   assigned-clock-parents = < IMX7D_PLL_AUDIO_POST_DIV>;
-   assigned-clock-rates = <0>, <24576000>;
-   status = "okay";
-};
-
- {
-   pinctrl-names = "default";
-   pinctrl-0 = <_uart5>;
-   assigned-clocks = < IMX7D_UART5_ROOT_SRC>;
-   assigned-clock-parents = < IMX7D_PLL_SYS_MAIN_240M_CLK>;
-   status = "okay";
-};
-
- {
-   vbus-supply = <_usb_otg1_vbus>;
-   status = "okay";
-};
-
- {
-   vbus-supply = <_usb_otg2_vbus>;
-   dr_mode = "host";
-   status = "okay";
-};
-
- {
-   pinctrl_enet1: enet1grp {
-   fsl,pins = <
-   MX7D_PAD_SD2_CD_B__ENET1_MDIO   0x3
-   MX7D_PAD_SD2_WP__ENET1_MDC  0x3
-   MX7D_PAD_ENET1_RGMII_TXC__ENET1_RGMII_TXC   0x1
-   MX7D_PAD_ENET1_RGMII_TD0__ENET1_RGMII_TD0   0x1
-   MX7D_PAD_ENET1_RGMII_TD1__ENET1_RGMII_TD1   0x1
-   MX7D_PAD_ENET1_RGMII_TD2__ENET1_RGMII_TD2   0x1
-   MX7D_PAD_ENET1_RGMII_TD3__ENET1_RGMII_TD3   0x1
-   MX7D_PAD_ENET1_RGMII_TX_CTL__ENET1_RGMII_TX_CTL 0x1
-   MX7D_PAD_ENET1_RGMII_RXC__ENET1_RGMII_RXC   0x1
-   MX7D_PAD_ENET1_RGMII_RD0__ENET1_RGMII_RD0   0x1
-   MX7D_PAD_ENET1_RGMII_RD1__ENET1_RGMII_RD1   0x1
-   MX7D_PAD_ENET1_RGMII_RD2__ENET1_RGMII_RD2   0x1
-   MX7D_PAD_ENET1_RGMII_RD3__ENET1_RGMII_RD3   0x1
-   MX7D_PAD_ENET1_RGMII_RX_CTL__ENET1_RGMII_RX_CTL 0x1
-   >;
-   };
-
-   pinctrl_i2c1: i2c1grp {
-   fsl,pins = <
-   MX7D_PAD_UART1_TX_DATA__I2C1_SDA0x407f
-   MX7D_PAD_UART1_RX_DATA__I2C1_SCL0x407f
-   >;
-   };
-
-   pinctrl_sai1: sai1grp {
-   fsl,pins = <
-   MX7D_PAD_ENET1_R

[PATCH 2/9] ARM: dts: imx7d-pico: Switch to SPDX identifier

2018-12-02 Thread Otavio Salvador
From: Fabio Estevam 

Adopt the SPDX license identifier headers to ease license compliance
management.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/imx7d-pico-pi.dts | 44 ++---
 arch/arm/boot/dts/imx7d-pico.dtsi   | 44 ++---
 2 files changed, 6 insertions(+), 82 deletions(-)

diff --git a/arch/arm/boot/dts/imx7d-pico-pi.dts 
b/arch/arm/boot/dts/imx7d-pico-pi.dts
index ee02d931cf49..33951f4c7f41 100644
--- a/arch/arm/boot/dts/imx7d-pico-pi.dts
+++ b/arch/arm/boot/dts/imx7d-pico-pi.dts
@@ -1,44 +1,6 @@
-/*
- * Copyright 2017 NXP
- *
- * This file is dual-licensed: you can use it either under the terms
- * of the GPL or the X11 license, at your option. Note that this dual
- * licensing only applies to this file, and not this project as a
- * whole.
- *
- *  a) This file is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of the
- * License, or (at your option) any later version.
- *
- * This file is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * Or, alternatively,
- *
- *  b) Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use,
- * copy, modify, merge, publish, distribute, sublicense, and/or
- * sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following
- * conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
- * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
- * OTHER DEALINGS IN THE SOFTWARE.
- */
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+//
+// Copyright 2017 NXP
 
 #include "imx7d-pico.dtsi"
 
diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index 0df68e53e9fa..d957454ce16b 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -1,44 +1,6 @@
-/*
- * Copyright 2017 NXP
- *
- * This file is dual-licensed: you can use it either under the terms
- * of the GPL or the X11 license, at your option. Note that this dual
- * licensing only applies to this file, and not this project as a
- * whole.
- *
- *  a) This file is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of the
- * License, or (at your option) any later version.
- *
- * This file is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * Or, alternatively,
- *
- *  b) Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use,
- * copy, modify, merge, publish, distribute, sublicense, and/or
- * sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following
- * conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
- * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
- * OTHER DEALINGS IN THE SOFTWARE.
- */
+// SPDX-License-Identi

[PATCH v2 4/9] ARM: dts: imx7d-pico: Pass the USBOTG1_PWR pinctrl

2018-12-06 Thread Otavio Salvador
From: Fabio Estevam 

Pass the USBOTG1_PWR pinctrl description in the USBOTG GPIO
controlled regulator.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/boot/dts/imx7d-pico.dtsi | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index 7319e2ecec5c..cb30bded1e4a 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -41,6 +41,8 @@
};
 
reg_usb_otg1_vbus: regulator-usb-otg1-vbus {
+   pinctrl-names = "default";
+   pinctrl-0 = <_usbotg1_pwr>;
compatible = "regulator-fixed";
regulator-name = "usb_otg1_vbus";
regulator-min-microvolt = <500>;
-- 
2.19.2



[PATCH v2 3/9] ARM: dts: imx7d-pico-pi: Move SoM related part to imx7d-pico.dtsi

2018-12-06 Thread Otavio Salvador
From: Fabio Estevam 

imx7d-pico-pi board contains:

- One SoM board (imx7d pico)
- One base board (pi).

In order to make it easier for adding support for other board variants,
move the commom SoM part to the imx7d-pico.dtsi file.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/boot/dts/imx7d-pico-pi.dts | 116 ++--
 arch/arm/boot/dts/imx7d-pico.dtsi   | 111 +-
 2 files changed, 113 insertions(+), 114 deletions(-)

diff --git a/arch/arm/boot/dts/imx7d-pico-pi.dts 
b/arch/arm/boot/dts/imx7d-pico-pi.dts
index 33951f4c7f41..039c17066fe0 100644
--- a/arch/arm/boot/dts/imx7d-pico-pi.dts
+++ b/arch/arm/boot/dts/imx7d-pico-pi.dts
@@ -5,6 +5,9 @@
 #include "imx7d-pico.dtsi"
 
 / {
+   model = "TechNexion PICO-IMX7D Board and PI baseboard";
+   compatible = "technexion,imx7d-pico-pi", "fsl,imx7d";
+
sound {
compatible = "simple-audio-card";
simple-audio-card,name = "imx7-sgtl5000";
@@ -16,43 +19,14 @@
};
 
dailink_master: simple-audio-card,codec {
-   sound-dai = <>;
+   sound-dai = <>;
clocks = < IMX7D_AUDIO_MCLK_ROOT_CLK>;
};
};
 };
 
- {
-   pinctrl-names = "default";
-   pinctrl-0 = <_enet1>;
-   assigned-clocks = < IMX7D_ENET1_TIME_ROOT_SRC>,
- < IMX7D_ENET1_TIME_ROOT_CLK>;
-   assigned-clock-parents = < IMX7D_PLL_ENET_MAIN_100M_CLK>;
-   assigned-clock-rates = <0>, <1>;
-   phy-mode = "rgmii";
-   phy-handle = <>;
-   fsl,magic-packet;
-   status = "okay";
-
-   mdio {
-   #address-cells = <1>;
-   #size-cells = <0>;
-
-   ethphy0: ethernet-phy@1 {
-   compatible = "ethernet-phy-ieee802.3-c22";
-   reg = <1>;
-   status = "okay";
-   };
-   };
-};
-
  {
-   clock-frequency = <10>;
-   pinctrl-names = "default";
-   pinctrl-0 = <_i2c1>;
-   status = "okay";
-
-   codec: sgtl5000@a {
+   sgtl5000: codec@a {
#sound-dai-cells = <0>;
reg = <0x0a>;
compatible = "fsl,sgtl5000";
@@ -61,83 +35,3 @@
VDDIO-supply = <_vref_1v8>;
};
 };
-
-
- {
-   pinctrl-names = "default";
-   pinctrl-0 = <_sai1>;
-   assigned-clocks = < IMX7D_SAI1_ROOT_SRC>,
- < IMX7D_SAI1_ROOT_CLK>;
-   assigned-clock-parents = < IMX7D_PLL_AUDIO_POST_DIV>;
-   assigned-clock-rates = <0>, <24576000>;
-   status = "okay";
-};
-
- {
-   pinctrl-names = "default";
-   pinctrl-0 = <_uart5>;
-   assigned-clocks = < IMX7D_UART5_ROOT_SRC>;
-   assigned-clock-parents = < IMX7D_PLL_SYS_MAIN_240M_CLK>;
-   status = "okay";
-};
-
- {
-   vbus-supply = <_usb_otg1_vbus>;
-   status = "okay";
-};
-
- {
-   vbus-supply = <_usb_otg2_vbus>;
-   dr_mode = "host";
-   status = "okay";
-};
-
- {
-   pinctrl_enet1: enet1grp {
-   fsl,pins = <
-   MX7D_PAD_SD2_CD_B__ENET1_MDIO   0x3
-   MX7D_PAD_SD2_WP__ENET1_MDC  0x3
-   MX7D_PAD_ENET1_RGMII_TXC__ENET1_RGMII_TXC   0x1
-   MX7D_PAD_ENET1_RGMII_TD0__ENET1_RGMII_TD0   0x1
-   MX7D_PAD_ENET1_RGMII_TD1__ENET1_RGMII_TD1   0x1
-   MX7D_PAD_ENET1_RGMII_TD2__ENET1_RGMII_TD2   0x1
-   MX7D_PAD_ENET1_RGMII_TD3__ENET1_RGMII_TD3   0x1
-   MX7D_PAD_ENET1_RGMII_TX_CTL__ENET1_RGMII_TX_CTL 0x1
-   MX7D_PAD_ENET1_RGMII_RXC__ENET1_RGMII_RXC   0x1
-   MX7D_PAD_ENET1_RGMII_RD0__ENET1_RGMII_RD0   0x1
-   MX7D_PAD_ENET1_RGMII_RD1__ENET1_RGMII_RD1   0x1
-   MX7D_PAD_ENET1_RGMII_RD2__ENET1_RGMII_RD2   0x1
-   MX7D_PAD_ENET1_RGMII_RD3__ENET1_RGMII_RD3   0x1
-   MX7D_PAD_ENET1_RGMII_RX_CTL__ENET1_RGMII_RX_CTL 0x1
-   >;
-   };
-
-   pinctrl_i2c1: i2c1grp {
-   fsl,pins = <
-   MX7D_PAD_UART1_TX_DATA__I2C1_SDA0x407f
-   MX7D_PAD_UART1_RX_DATA__I2C1_SCL0x407f
-   >;
-   };
-
-   pinctrl_sai1: sai1grp {

[PATCH v2 0/9] Improvements for i.MX7D PICO SoM and its baseboards

2018-12-06 Thread Otavio Salvador
This patchset rework the imx7d-pico SoM, its Pi baseboard
and add the Hobbit baseboard support as well.

Changes in v2:
- replace fsl,uart-has-rtscts with uart-has-rtscts

Fabio Estevam (8):
  ARM: dts: imx7d-pico: Do not harcode the memory size
  ARM: dts: imx7d-pico: Switch to SPDX identifier
  ARM: dts: imx7d-pico-pi: Move SoM related part to imx7d-pico.dtsi
  ARM: dts: imx7d-pico: Pass the USBOTG1_PWR pinctrl
  ARM: dts: imx7d-pico: Pass the Ethernet PHY reset GPIO
  ARM: dts: imx7d-pico: Extend peripherals support
  ARM: dts: imx7d-pico-pi: Extend peripherals support
  ARM: dts: imx7d-pico: Add the imx7d-pico-hobbit variant

Otavio Salvador (1):
  ARM: dts: imx7d-pico: Improve WiFi regulator name

 arch/arm/boot/dts/Makefile  |   1 +
 arch/arm/boot/dts/imx7d-pico-hobbit.dts | 105 +++
 arch/arm/boot/dts/imx7d-pico-pi.dts | 180 +++-
 arch/arm/boot/dts/imx7d-pico.dtsi   | 355 
 4 files changed, 457 insertions(+), 184 deletions(-)
 create mode 100644 arch/arm/boot/dts/imx7d-pico-hobbit.dts

-- 
2.19.2



[PATCH v2 2/9] ARM: dts: imx7d-pico: Switch to SPDX identifier

2018-12-06 Thread Otavio Salvador
From: Fabio Estevam 

Adopt the SPDX license identifier headers to ease license compliance
management.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/boot/dts/imx7d-pico-pi.dts | 44 ++---
 arch/arm/boot/dts/imx7d-pico.dtsi   | 44 ++---
 2 files changed, 6 insertions(+), 82 deletions(-)

diff --git a/arch/arm/boot/dts/imx7d-pico-pi.dts 
b/arch/arm/boot/dts/imx7d-pico-pi.dts
index ee02d931cf49..33951f4c7f41 100644
--- a/arch/arm/boot/dts/imx7d-pico-pi.dts
+++ b/arch/arm/boot/dts/imx7d-pico-pi.dts
@@ -1,44 +1,6 @@
-/*
- * Copyright 2017 NXP
- *
- * This file is dual-licensed: you can use it either under the terms
- * of the GPL or the X11 license, at your option. Note that this dual
- * licensing only applies to this file, and not this project as a
- * whole.
- *
- *  a) This file is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of the
- * License, or (at your option) any later version.
- *
- * This file is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * Or, alternatively,
- *
- *  b) Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use,
- * copy, modify, merge, publish, distribute, sublicense, and/or
- * sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following
- * conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
- * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
- * OTHER DEALINGS IN THE SOFTWARE.
- */
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+//
+// Copyright 2017 NXP
 
 #include "imx7d-pico.dtsi"
 
diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index 0df68e53e9fa..d957454ce16b 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -1,44 +1,6 @@
-/*
- * Copyright 2017 NXP
- *
- * This file is dual-licensed: you can use it either under the terms
- * of the GPL or the X11 license, at your option. Note that this dual
- * licensing only applies to this file, and not this project as a
- * whole.
- *
- *  a) This file is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of the
- * License, or (at your option) any later version.
- *
- * This file is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * Or, alternatively,
- *
- *  b) Permission is hereby granted, free of charge, to any person
- * obtaining a copy of this software and associated documentation
- * files (the "Software"), to deal in the Software without
- * restriction, including without limitation the rights to use,
- * copy, modify, merge, publish, distribute, sublicense, and/or
- * sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following
- * conditions:
- *
- * The above copyright notice and this permission notice shall be
- * included in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
- * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
- * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
- * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
- * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
- * OTHER DEALINGS IN THE SOFTWARE.

[PATCH v2 1/9] ARM: dts: imx7d-pico: Do not harcode the memory size

2018-12-06 Thread Otavio Salvador
From: Fabio Estevam 

Currently the memory size described in dts is 2GB, which is incorrect.

There are 512MB and 1GB versions of imx7d-pico boards, so remove
the hardcoded memory size and let the bootloader pass the correct
value to the kernel.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/boot/dts/imx7d-pico.dtsi | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index 934a019f341e..0df68e53e9fa 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -48,9 +48,10 @@
model = "Technexion Pico i.MX7D Board";
compatible = "technexion,imx7d-pico", "fsl,imx7d";
 
+   /* Will be filled by the bootloader */
memory@8000 {
device_type = "memory";
-   reg = <0x8000 0x8000>;
+   reg = <0x8000 0>;
};
 
reg_ap6212: regulator-ap6212 {
-- 
2.19.2



[PATCH v2 6/9] ARM: dts: imx7d-pico: Improve WiFi regulator name

2018-12-06 Thread Otavio Salvador
There are different models of WiFi being used in the SoM and the
handle name was too restrictive. This reworks it to a more generic and
meaningful name.

Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/boot/dts/imx7d-pico.dtsi | 10 +-
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index 35791a1adabf..417f034fb354 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -13,11 +13,11 @@
reg = <0x8000 0>;
};
 
-   reg_ap6212: regulator-ap6212 {
+   reg_wlreg_on: regulator-wlreg_on {
compatible = "regulator-fixed";
pinctrl-names = "default";
-   pinctrl-0 = <_reg_ap6212>;
-   regulator-name = "AP6212";
+   pinctrl-0 = <_reg_wlreg_on>;
+   regulator-name = "wlreg_on";
regulator-min-microvolt = <330>;
regulator-max-microvolt = <330>;
gpio = < 16 GPIO_ACTIVE_HIGH>;
@@ -241,7 +241,7 @@
non-removable;
keep-power-in-suspend;
wakeup-source;
-   vmmc-supply = <_ap6212>;
+   vmmc-supply = <_wlreg_on>;
mmc-pwrseq = <_pwrseq>;
status = "okay";
 };
@@ -302,7 +302,7 @@
>;
};
 
-   pinctrl_reg_ap6212: regap6212grp {
+   pinctrl_reg_wlreg_on: regregongrp {
fsl,pins = <
MX7D_PAD_ECSPI1_SCLK__GPIO4_IO160x59
>;
-- 
2.19.2



Re: [PATCH v2 0/9] Improvements for i.MX7D PICO SoM and its baseboards

2018-12-06 Thread Otavio Salvador
On Thu, Dec 6, 2018 at 8:09 AM Otavio Salvador  wrote:
>
> This patchset rework the imx7d-pico SoM, its Pi baseboard
> and add the Hobbit baseboard support as well.
>
> Changes in v2:
> - replace fsl,uart-has-rtscts with uart-has-rtscts
>
> Fabio Estevam (8):
>   ARM: dts: imx7d-pico: Do not harcode the memory size
>   ARM: dts: imx7d-pico: Switch to SPDX identifier
>   ARM: dts: imx7d-pico-pi: Move SoM related part to imx7d-pico.dtsi

I did the rebase; one thing worth mentioning is that I have "ARM: dts:
imx7d-pico: Describe the Wifi clock" which is in your fixes tree.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854  Mobile: +1 (347) 903-9750


[PATCH v2 9/9] ARM: dts: imx7d-pico: Add the imx7d-pico-hobbit variant

2018-12-06 Thread Otavio Salvador
From: Fabio Estevam 

The imx7d-pico-hobbit contains a imx7d-pico SoM and a hobbit baseboard.

Add support for it.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/boot/dts/Makefile  |   1 +
 arch/arm/boot/dts/imx7d-pico-hobbit.dts | 105 
 2 files changed, 106 insertions(+)
 create mode 100644 arch/arm/boot/dts/imx7d-pico-hobbit.dts

diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile
index 1d6d916c2195..5c7dc0b4aaa8 100644
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
@@ -572,6 +572,7 @@ dtb-$(CONFIG_SOC_IMX7D) += \
imx7d-colibri-emmc-eval-v3.dtb \
imx7d-colibri-eval-v3.dtb \
imx7d-nitrogen7.dtb \
+   imx7d-pico-hobbit.dtb \
imx7d-pico-pi.dtb \
imx7d-sbc-imx7.dtb \
imx7d-sdb.dtb \
diff --git a/arch/arm/boot/dts/imx7d-pico-hobbit.dts 
b/arch/arm/boot/dts/imx7d-pico-hobbit.dts
new file mode 100644
index ..7b2198a9372c
--- /dev/null
+++ b/arch/arm/boot/dts/imx7d-pico-hobbit.dts
@@ -0,0 +1,105 @@
+// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
+//
+// Copyright 2017 NXP
+
+#include "imx7d-pico.dtsi"
+
+/ {
+   model = "TechNexion PICO-IMX7D Board using Hobbit baseboard";
+   compatible = "technexion,imx7d-pico-hobbit", "fsl,imx7d";
+
+   leds {
+   compatible = "gpio-leds";
+   pinctrl-names = "default";
+   pinctrl-0 = <_gpio_leds>;
+
+   led {
+   label = "gpio-led";
+   gpios = < 13 GPIO_ACTIVE_HIGH>;
+   };
+   };
+
+   sound {
+   compatible = "simple-audio-card";
+   simple-audio-card,name = "imx7-sgtl5000";
+   simple-audio-card,format = "i2s";
+   simple-audio-card,bitclock-master = <_master>;
+   simple-audio-card,frame-master = <_master>;
+   simple-audio-card,cpu {
+   sound-dai = <>;
+   };
+
+   dailink_master: simple-audio-card,codec {
+   sound-dai = <>;
+   clocks = < IMX7D_AUDIO_MCLK_ROOT_CLK>;
+   };
+   };
+};
+
+ {
+   sgtl5000: codec@a {
+   #sound-dai-cells = <0>;
+   reg = <0x0a>;
+   compatible = "fsl,sgtl5000";
+   clocks = < IMX7D_AUDIO_MCLK_ROOT_CLK>;
+   VDDA-supply = <_2p5v>;
+   VDDIO-supply = <_vref_1v8>;
+   };
+};
+
+ {
+   status = "okay";
+
+   adc081c: adc@50 {
+   compatible = "ti,adc081c";
+   reg = <0x50>;
+   vref-supply = <_3p3v>;
+   };
+};
+
+ {
+   ads7846@0 {
+   reg = <0>;
+   compatible = "ti,ads7846";
+   interrupt-parent = <>;
+   interrupts = <7 0>;
+   spi-max-frequency = <100>;
+   pendown-gpio = < 7 0>;
+   vcc-supply = <_3p3v>;
+   ti,x-min = /bits/ 16 <0>;
+   ti,x-max = /bits/ 16 <4095>;
+   ti,y-min = /bits/ 16 <0>;
+   ti,y-max = /bits/ 16 <4095>;
+   ti,pressure-max = /bits/ 16 <1024>;
+   ti,x-plate-ohms = /bits/ 16 <90>;
+   ti,y-plate-ohms = /bits/ 16 <90>;
+   ti,debounce-max = /bits/ 16 <70>;
+   ti,debounce-tol = /bits/ 16 <3>;
+   ti,debounce-rep = /bits/ 16 <2>;
+   ti,settle-delay-usec = /bits/ 16 <150>;
+   wakeup-source;
+   };
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_hog>;
+
+   pinctrl_hog: hoggrp {
+   fsl,pins = <
+   MX7D_PAD_EPDC_DATA00__GPIO2_IO0 0x14
+   MX7D_PAD_EPDC_DATA01__GPIO2_IO1 0x14
+   MX7D_PAD_EPDC_DATA02__GPIO2_IO2 0x14
+   MX7D_PAD_EPDC_DATA03__GPIO2_IO3 0x14
+   MX7D_PAD_EPDC_DATA05__GPIO2_IO5 0x14
+   MX7D_PAD_EPDC_DATA12__GPIO2_IO120x14
+   MX7D_PAD_EPDC_DATA07__GPIO2_IO7 0x14
+   >;
+   };
+
+   pinctrl_gpio_leds: gpioledsgrp {
+   fsl,pins = <
+   MX7D_PAD_EPDC_DATA13__GPIO2_IO130x14
+   >;
+   };
+};
-- 
2.19.2



[PATCH v2 7/9] ARM: dts: imx7d-pico: Extend peripherals support

2018-12-06 Thread Otavio Salvador
From: Fabio Estevam 

This extends the peripherals supported by the imx7d-pico.dtsi. It
adds:

 - I2C2
 - Flexcan (flexcan1 and flexcan2 ports)
 - USDHC1
 - UART (6 and 7 ports)
 - PWM (4 ports)
 - eCSPI3

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

Changes in v2:
- replace fsl,uart-has-rtscts with uart-has-rtscts

 arch/arm/boot/dts/imx7d-pico.dtsi | 183 ++
 1 file changed, 183 insertions(+)

diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index 417f034fb354..3fd595a71202 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -78,6 +78,13 @@
assigned-clock-rates = <0>, <32768>;
 };
 
+ {
+   cs-gpios = < 11 GPIO_ACTIVE_LOW>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_ecspi3>;
+   status = "okay";
+};
+
  {
pinctrl-names = "default";
pinctrl-0 = <_enet1>;
@@ -103,6 +110,18 @@
};
 };
 
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_can1>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_can2>;
+   status = "okay";
+};
+
  {
clock-frequency = <10>;
pinctrl-names = "default";
@@ -110,6 +129,12 @@
status = "okay";
 };
 
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_i2c2>;
+   status = "okay";
+};
+
  {
pinctrl-names = "default";
pinctrl-0 = <_i2c4>;
@@ -215,6 +240,29 @@
status = "okay";
 };
 
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pwm1>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pwm2>;
+   status = "okay";
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_pwm3>;
+   status = "okay";
+};
+
+ { /* Backlight */
+   status = "okay";
+};
+
  {
pinctrl-names = "default";
pinctrl-0 = <_uart5>;
@@ -223,6 +271,24 @@
status = "okay";
 };
 
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_uart6>;
+   assigned-clocks = < IMX7D_UART6_ROOT_SRC>;
+   assigned-clock-parents = < IMX7D_OSC_24M_CLK>;
+   uart-has-rtscts;
+   status = "okay";
+};
+
+ { /* Bluetooth */
+   pinctrl-names = "default";
+   pinctrl-0 = <_uart7>;
+   assigned-clocks = < IMX7D_UART7_ROOT_SRC>;
+   assigned-clock-parents = < IMX7D_PLL_SYS_MAIN_240M_CLK>;
+   uart-has-rtscts;
+   status = "okay";
+};
+
  {
vbus-supply = <_usb_otg1_vbus>;
status = "okay";
@@ -234,6 +300,21 @@
status = "okay";
 };
 
+ {
+   pinctrl-names = "default", "state_100mhz", "state_200mhz";
+   pinctrl-0 = <_usdhc1>;
+   pinctrl-1 = <_usdhc1_100mhz>;
+   pinctrl-2 = <_usdhc1_200mhz>;
+   cd-gpios = < 0 GPIO_ACTIVE_LOW>;
+   bus-width = <4>;
+   tuning-step = <2>;
+   vmmc-supply = <_3p3v>;
+   wakeup-source;
+   no-1-8-v;
+   keep-power-in-suspend;
+   status = "okay";
+};
+
  { /* Wifi SDIO */
pinctrl-names = "default";
pinctrl-0 = <_usdhc2 _wifi_clk>;
@@ -268,6 +349,15 @@
 };
 
  {
+   pinctrl_ecspi3: ecspi3grp {
+   fsl,pins = <
+   MX7D_PAD_I2C1_SCL__ECSPI3_MISO  0x2
+   MX7D_PAD_I2C1_SDA__ECSPI3_MOSI  0x2
+   MX7D_PAD_I2C2_SCL__ECSPI3_SCLK  0x2
+   MX7D_PAD_I2C2_SDA__GPIO4_IO11   0x14
+   >;
+   };
+
pinctrl_i2c1: i2c1grp {
fsl,pins = <
MX7D_PAD_UART1_TX_DATA__I2C1_SDA0x407f
@@ -275,6 +365,13 @@
>;
};
 
+   pinctrl_i2c2: i2c2grp {
+   fsl,pins = <
+   MX7D_PAD_UART2_TX_DATA__I2C2_SDA0x407f
+   MX7D_PAD_UART2_RX_DATA__I2C2_SCL0x407f
+   >;
+   };
+
pinctrl_enet1: enet1grp {
fsl,pins = <
MX7D_PAD_SD2_CD_B__ENET1_MDIO   0x3
@@ -295,6 +392,20 @@
>;
};
 
+   pinctrl_can1: can1frp {
+   fsl,pins = <
+   MX7D_PAD_SAI1_RX_DATA__FLEXCAN1_RX  0x59
+   MX7D_PAD_SAI1_TX_BCLK__FLEXCAN1_TX  0x59
+   >;
+   };
+
+   pinctrl_can2: can2frp {
+   fsl,pins = <
+   MX

[PATCH v2 5/9] ARM: dts: imx7d-pico: Pass the Ethernet PHY reset GPIO

2018-12-06 Thread Otavio Salvador
From: Fabio Estevam 

Pass the "phy-reset-gpios" property in order to describe the GPIO
that performs the Ethernet PHY reset.

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/boot/dts/imx7d-pico.dtsi | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/boot/dts/imx7d-pico.dtsi 
b/arch/arm/boot/dts/imx7d-pico.dtsi
index cb30bded1e4a..35791a1adabf 100644
--- a/arch/arm/boot/dts/imx7d-pico.dtsi
+++ b/arch/arm/boot/dts/imx7d-pico.dtsi
@@ -88,6 +88,7 @@
phy-mode = "rgmii";
phy-handle = <>;
fsl,magic-packet;
+   phy-reset-gpios = < 11 GPIO_ACTIVE_LOW>;
status = "okay";
 
mdio {
@@ -290,6 +291,7 @@
MX7D_PAD_ENET1_RGMII_RD2__ENET1_RGMII_RD2   0x1
MX7D_PAD_ENET1_RGMII_RD3__ENET1_RGMII_RD3   0x1
MX7D_PAD_ENET1_RGMII_RX_CTL__ENET1_RGMII_RX_CTL 0x1
+   MX7D_PAD_SD3_RESET_B__GPIO6_IO110x1  /* 
Ethernet reset */
>;
};
 
-- 
2.19.2



[PATCH v2 8/9] ARM: dts: imx7d-pico-pi: Extend peripherals support

2018-12-06 Thread Otavio Salvador
From: Fabio Estevam 

This adds following peripherals for the imx7d-pico-pi as:

 - LED
 - Touchscreen
 - GPIO

Signed-off-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/boot/dts/imx7d-pico-pi.dts | 56 +
 1 file changed, 56 insertions(+)

diff --git a/arch/arm/boot/dts/imx7d-pico-pi.dts 
b/arch/arm/boot/dts/imx7d-pico-pi.dts
index 039c17066fe0..70bea95c06d8 100644
--- a/arch/arm/boot/dts/imx7d-pico-pi.dts
+++ b/arch/arm/boot/dts/imx7d-pico-pi.dts
@@ -8,6 +8,17 @@
model = "TechNexion PICO-IMX7D Board and PI baseboard";
compatible = "technexion,imx7d-pico-pi", "fsl,imx7d";
 
+   leds {
+   compatible = "gpio-leds";
+   pinctrl-names = "default";
+   pinctrl-0 = <_gpio_leds>;
+
+   led {
+   label = "gpio-led";
+   gpios = < 6 GPIO_ACTIVE_HIGH>;
+   };
+   };
+
sound {
compatible = "simple-audio-card";
simple-audio-card,name = "imx7-sgtl5000";
@@ -35,3 +46,48 @@
VDDIO-supply = <_vref_1v8>;
};
 };
+
+ {
+   polytouch: touchscreen@38 {
+   compatible = "edt,edt-ft5x06";
+   reg = <0x38>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_touchscreen>;
+   interrupt-parent = <>;
+   interrupts = <13 IRQ_TYPE_EDGE_FALLING>;
+   reset-gpios = < 4 GPIO_ACTIVE_LOW>;
+   touchscreen-size-x = <800>;
+   touchscreen-size-y = <480>;
+   };
+};
+
+ {
+   pinctrl-names = "default";
+   pinctrl-0 = <_hog>;
+
+   pinctrl_hog: hoggrp {
+   fsl,pins = <
+   MX7D_PAD_EPDC_DATA00__GPIO2_IO0 0x14
+   MX7D_PAD_EPDC_DATA01__GPIO2_IO1 0x14
+   MX7D_PAD_EPDC_DATA02__GPIO2_IO2 0x14
+   MX7D_PAD_EPDC_DATA03__GPIO2_IO3 0x14
+   MX7D_PAD_EPDC_DATA05__GPIO2_IO5 0x14
+   MX7D_PAD_EPDC_DATA12__GPIO2_IO120x14
+   MX7D_PAD_EPDC_DATA07__GPIO2_IO7 0x14
+   >;
+   };
+
+   pinctrl_gpio_leds: gpioledsgrp {
+   fsl,pins = <
+   MX7D_PAD_EPDC_DATA06__GPIO2_IO6 0x14
+   >;
+   };
+
+   pinctrl_touchscreen: touchscreengrp {
+   fsl,pins = <
+   MX7D_PAD_EPDC_DATA04__GPIO2_IO4 0x14
+   MX7D_PAD_EPDC_DATA13__GPIO2_IO130x14
+   >;
+   };
+
+};
-- 
2.19.2



Re: [PATCH] ARM: imx_v6_v7_defconfig: Enable ATH10K SDIO support

2018-12-03 Thread Otavio Salvador
On Sat, Dec 1, 2018 at 5:39 PM Otavio Salvador  wrote:
> The use of ATH10K WiFi is becoming common in i.MX based boards,
> especially on new designs, so enable the driver support as module so
> it can be used out of box.
>
> Signed-off-by: Otavio Salvador 

Please ignore this patch for now, the driver did not work on the
custom board ... once we get it working, I resend the patch.

Sorry for the noise.

Best regards

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854  Mobile: +1 (347) 903-9750


[PATCH 01/13] ARM: multi_v7_defconfig: Select PHY_ROCKCHIP_INNO_USB2

2018-11-25 Thread Otavio Salvador
Select the CONFIG_PHY_ROCKCHIP_INNO_USB2 option by default, so that
USB can be functional on RV1108.

Signed-off-by: Otavio Salvador 
---

 arch/arm/configs/multi_v7_defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/configs/multi_v7_defconfig 
b/arch/arm/configs/multi_v7_defconfig
index 63af6234c1b6..a8ec309d182a 100644
--- a/arch/arm/configs/multi_v7_defconfig
+++ b/arch/arm/configs/multi_v7_defconfig
@@ -947,6 +947,7 @@ CONFIG_PHY_CPCAP_USB=m
 CONFIG_PHY_QCOM_APQ8064_SATA=m
 CONFIG_PHY_RCAR_GEN2=m
 CONFIG_PHY_ROCKCHIP_DP=m
+CONFIG_PHY_ROCKCHIP_INNO_USB2=y
 CONFIG_PHY_ROCKCHIP_USB=y
 CONFIG_PHY_SAMSUNG_USB2=m
 CONFIG_PHY_MIPHY28LP=y
-- 
2.19.1



[PATCH 09/13] ARM: dts: rv1108: Assign the proper GPIO clocks

2018-11-25 Thread Otavio Salvador
It is not correct to assign the 24MHz clock oscillator to the GPIO
ports.

Fix it by assigning the proper GPIO clocks instead.

Signed-off-by: Otavio Salvador 
Signed-off-by: Fabio Berton 
---

 arch/arm/boot/dts/rv1108.dtsi | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/arm/boot/dts/rv1108.dtsi b/arch/arm/boot/dts/rv1108.dtsi
index 442b749eb2e9..ce5509c4657b 100644
--- a/arch/arm/boot/dts/rv1108.dtsi
+++ b/arch/arm/boot/dts/rv1108.dtsi
@@ -562,7 +562,7 @@
compatible = "rockchip,gpio-bank";
reg = <0x2003 0x100>;
interrupts = ;
-   clocks = <>;
+   clocks = < PCLK_GPIO0_PMU>;
 
gpio-controller;
#gpio-cells = <2>;
@@ -575,7 +575,7 @@
compatible = "rockchip,gpio-bank";
reg = <0x1031 0x100>;
interrupts = ;
-   clocks = <>;
+   clocks = < PCLK_GPIO1>;
 
gpio-controller;
#gpio-cells = <2>;
@@ -588,7 +588,7 @@
compatible = "rockchip,gpio-bank";
reg = <0x1032 0x100>;
interrupts = ;
-   clocks = <>;
+   clocks = < PCLK_GPIO2>;
 
gpio-controller;
#gpio-cells = <2>;
@@ -601,7 +601,7 @@
compatible = "rockchip,gpio-bank";
reg = <0x1033 0x100>;
interrupts = ;
-   clocks = <>;
+   clocks = < PCLK_GPIO3>;
 
gpio-controller;
#gpio-cells = <2>;
-- 
2.19.1



[PATCH 10/13] ARM: dts: rv1108: Add UART DMA support

2018-11-25 Thread Otavio Salvador
Pass the 'dmas' property to the UART ports so that DMA can
be supported.

Signed-off-by: Otavio Salvador 
Signed-off-by: Fabio Berton 
---

 arch/arm/boot/dts/rv1108.dtsi | 6 ++
 1 file changed, 6 insertions(+)

diff --git a/arch/arm/boot/dts/rv1108.dtsi b/arch/arm/boot/dts/rv1108.dtsi
index ce5509c4657b..7ef6d965871c 100644
--- a/arch/arm/boot/dts/rv1108.dtsi
+++ b/arch/arm/boot/dts/rv1108.dtsi
@@ -114,6 +114,8 @@
interrupts = ;
reg-shift = <2>;
reg-io-width = <4>;
+   dmas = < 6>, < 7>;
+   #dma-cells = <2>;
clock-frequency = <2400>;
clocks = < SCLK_UART2>, < PCLK_UART2>;
clock-names = "baudclk", "apb_pclk";
@@ -128,6 +130,8 @@
interrupts = ;
reg-shift = <2>;
reg-io-width = <4>;
+   dmas = < 4>, < 5>;
+   #dma-cells = <2>;
clock-frequency = <2400>;
clocks = < SCLK_UART1>, < PCLK_UART1>;
clock-names = "baudclk", "apb_pclk";
@@ -142,6 +146,8 @@
interrupts = ;
reg-shift = <2>;
reg-io-width = <4>;
+   dmas = < 2>, < 3>;
+   #dma-cells = <2>;
clock-frequency = <2400>;
clocks = < SCLK_UART0>, < PCLK_UART0>;
clock-names = "baudclk", "apb_pclk";
-- 
2.19.1



[PATCH 08/13] ARM: dts: rv1108: Fix the PMU interrupt number

2018-11-25 Thread Otavio Salvador
According to the Rockchip vendor tree the PMU interrupt number is
76, so fix it accordingly.

Signed-off-by: Otavio Salvador 
Signed-off-by: Fabio Berton 
---

 arch/arm/boot/dts/rv1108.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/rv1108.dtsi b/arch/arm/boot/dts/rv1108.dtsi
index 7b331766120d..442b749eb2e9 100644
--- a/arch/arm/boot/dts/rv1108.dtsi
+++ b/arch/arm/boot/dts/rv1108.dtsi
@@ -66,7 +66,7 @@
 
arm-pmu {
compatible = "arm,cortex-a7-pmu";
-   interrupts = ;
+   interrupts = ;
};
 
timer {
-- 
2.19.1



[PATCH 13/13] ARM: dts: rv1108: Pass the 'clock-latency' property

2018-11-25 Thread Otavio Salvador
Like it is done on cpu nodes of other Rockchip SoCs, pass the
'clock-latency' property to the CPU node, so that cpufreq driver
can take the latency into account when switching frequencies.

Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/rv1108.dtsi | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/boot/dts/rv1108.dtsi b/arch/arm/boot/dts/rv1108.dtsi
index d96c58728b28..4e1ca13a1636 100644
--- a/arch/arm/boot/dts/rv1108.dtsi
+++ b/arch/arm/boot/dts/rv1108.dtsi
@@ -36,6 +36,7 @@
#cooling-cells = <2>; /* min followed by max */
dynamic-power-coefficient = <75>;
operating-points-v2 = <_opp_table>;
+   clock-latency = <4>;
};
};
 
-- 
2.19.1



[PATCH 11/13] ARM: dts: rv1108: Add internal timer support

2018-11-25 Thread Otavio Salvador
Add support for the internal timer peripheral on RV1108.

Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/rv1108.dtsi | 8 
 1 file changed, 8 insertions(+)

diff --git a/arch/arm/boot/dts/rv1108.dtsi b/arch/arm/boot/dts/rv1108.dtsi
index 7ef6d965871c..42566adadc83 100644
--- a/arch/arm/boot/dts/rv1108.dtsi
+++ b/arch/arm/boot/dts/rv1108.dtsi
@@ -291,6 +291,14 @@
};
};
 
+   timer: timer@1035 {
+   compatible = "rockchip,rv1108-timer", "rockchip,rk3288-timer";
+   reg = <0x1035 0x20>;
+   interrupts = ;
+   clocks = <>, < PCLK_TIMER>;
+   clock-names = "timer", "pclk";
+   };
+
watchdog: wdt@1036 {
compatible = "snps,dw-wdt";
reg = <0x1036 0x100>;
-- 
2.19.1



[PATCH 12/13] ARM: dts: rv1108: Pass the 'arm,cpu-registers-not-fw-configured' property

2018-11-25 Thread Otavio Salvador
Since firmware does not initialize  any of the generic timer CPU
registers pass the 'arm,cpu-registers-not-fw-configured' property as
suggested in Documentation/devicetree/bindings/timer/arm,arch_timer.txt.

This also aligns with other Rockchip SoC dtsi files.

Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/rv1108.dtsi | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/boot/dts/rv1108.dtsi b/arch/arm/boot/dts/rv1108.dtsi
index 42566adadc83..d96c58728b28 100644
--- a/arch/arm/boot/dts/rv1108.dtsi
+++ b/arch/arm/boot/dts/rv1108.dtsi
@@ -71,6 +71,7 @@
 
timer {
compatible = "arm,armv7-timer";
+   arm,cpu-registers-not-fw-configured;
interrupts = ,
 ;
clock-frequency = <2400>;
-- 
2.19.1



Re: [PATCH v2 1/3] ARM: imx_v6_v7_defconfig: Remove explicit ARM_UNWIND disable

2018-11-25 Thread Otavio Salvador
On Sun, Nov 25, 2018 at 7:35 PM Arnd Bergmann  wrote:
> On Sun, Nov 25, 2018 at 10:24 PM Otavio Salvador
>  wrote:
> >
> > CONFIG_ARM_UNWIND is removed when running 'savedefconfig', but
> > selected by the Kconfig logic.  This is done in preparation to making
> > further changes to this defconfig cleaner.
> >
>
> Does this mean we no longer get the unwinder, or there is some other
> config (which?) that unconditionally selects it?

It is selected. Before changing the defconfig I did a savedefconfig to
avoid unrelated changes to be included on the subsequent patches and
then I found it was now selected.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854  Mobile: +1 (347) 903-9750


[PATCH v3 3/3] ARM: imx_v6_v7_defconfig: Enable USB_ANNOUNCE_NEW_DEVICES

2018-11-25 Thread Otavio Salvador
From: Andreas Müller 

This is very helpful debugging USB issues.

Reviewed-by: Fabio Estevam 
Signed-off-by: Andreas Müller 
Signed-off-by: Otavio Salvador 
---

Changes in v3: None
Changes in v2: None

 arch/arm/configs/imx_v6_v7_defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/configs/imx_v6_v7_defconfig 
b/arch/arm/configs/imx_v6_v7_defconfig
index 22ad2d7a1cf2..d339913845fa 100644
--- a/arch/arm/configs/imx_v6_v7_defconfig
+++ b/arch/arm/configs/imx_v6_v7_defconfig
@@ -305,6 +305,7 @@ CONFIG_SND_SOC_WM8962=y
 CONFIG_SND_SIMPLE_CARD=y
 CONFIG_HID_MULTITOUCH=y
 CONFIG_USB=y
+CONFIG_USB_ANNOUNCE_NEW_DEVICES=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_EHCI_MXC=y
 CONFIG_USB_STORAGE=y
-- 
2.19.2



[PATCH v3 2/3] ARM: imx_v6_v7_defconfig: Enable BT_BNEP

2018-11-25 Thread Otavio Salvador
From: Andreas Müller 

This is necessary to support network over bluetooth:

| Sep 11 15:36:33 imx6qdl-variscite-som bluetoothd[281]: kernel lacks 
bnep-protocol support
| Sep 11 15:36:33 imx6qdl-variscite-som bluetoothd[281]: System does not 
support network plugin

Reviewed-by: Fabio Estevam 
Signed-off-by: Andreas Müller 
Signed-off-by: Otavio Salvador 
---

Changes in v3: None
Changes in v2: None

 arch/arm/configs/imx_v6_v7_defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/configs/imx_v6_v7_defconfig 
b/arch/arm/configs/imx_v6_v7_defconfig
index 0c887a059df3..22ad2d7a1cf2 100644
--- a/arch/arm/configs/imx_v6_v7_defconfig
+++ b/arch/arm/configs/imx_v6_v7_defconfig
@@ -81,6 +81,7 @@ CONFIG_NETFILTER=y
 CONFIG_CAN=y
 CONFIG_CAN_FLEXCAN=y
 CONFIG_BT=y
+CONFIG_BT_BNEP=m
 CONFIG_BT_HCIUART=y
 CONFIG_BT_HCIUART_LL=y
 CONFIG_CFG80211=y
-- 
2.19.2



[PATCH v3 1/3] ARM: imx_v6_v7_defconfig: Remove explicit ARM_UNWIND disable

2018-11-25 Thread Otavio Salvador
CONFIG_ARM_UNWIND is removed when running 'savedefconfig', but
selected by ARM EABI (AEBI) support.  This is done in preparation to making
further changes to this defconfig cleaner.

Reviewed-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

Changes in v3:
- mention it is enabled by ARM EABI support (Arnd Bergmann)

Changes in v2:
- rework commit log (Fabio Estevam)

 arch/arm/configs/imx_v6_v7_defconfig | 1 -
 1 file changed, 1 deletion(-)

diff --git a/arch/arm/configs/imx_v6_v7_defconfig 
b/arch/arm/configs/imx_v6_v7_defconfig
index aa02d18f44d1..0c887a059df3 100644
--- a/arch/arm/configs/imx_v6_v7_defconfig
+++ b/arch/arm/configs/imx_v6_v7_defconfig
@@ -445,4 +445,3 @@ CONFIG_MAGIC_SYSRQ=y
 CONFIG_PROVE_LOCKING=y
 # CONFIG_DEBUG_BUGVERBOSE is not set
 # CONFIG_FTRACE is not set
-# CONFIG_ARM_UNWIND is not set
-- 
2.19.2



Re: [PATCH 02/13] ARM: multi_v7_defconfig: Add missing systemd options

2018-11-25 Thread Otavio Salvador
Hello Olof,

On Sun, Nov 25, 2018 at 8:25 PM Olof Johansson  wrote:
> Thanks for these patches. I don't have a reason to _not_ enable
> systemd features, but would you mind providing a brief description of
> what's not working without this change? Is it completely broken, or is
> it just the random-UID featues that don't work, or something else?.
> Useful for others to know what's expected to break if someone turns
> them off, etc.

Thank you for your kindness reviewing this. I am not an experienced
Linux kernel contributor so I am going to do some mistakes during this
process.

We usually follow the required feature set listed on Gentoo wiki[1] as
it is usually up to date and avoids a lot of headaches for us when
dealing with boot issues with SystemD.

1. https://wiki.gentoo.org/wiki/Systemd#Kernel

Do you think mentioning where it has been taken from is enough?

> Also, I noticed you posted a series of 13 patches, which includes some
> dts files for rv1108, some network driver changes and some of these
> more generic defconfig changes. I would suggest that you split up your
> patches into independent series where possible, especially when they
> end up going to different subsystems. Providing suitable cover letters
> for the series when you post them is also useful to help reviewers by
> summarizing the series, including changes from last time it was
> posted, etc. Please address it to the superset of patch receivers on
> the series.

I can certainly improve it for the next submission. Should I split
them all and tag them v2 to easy it?

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854  Mobile: +1 (347) 903-9750


Re: [PATCH v2 1/3] ARM: imx_v6_v7_defconfig: Remove explicit ARM_UNWIND disable

2018-11-25 Thread Otavio Salvador
Hello Arnd,

On Sun, Nov 25, 2018 at 7:48 PM Arnd Bergmann  wrote:
> On Sun, Nov 25, 2018 at 10:45 PM Otavio Salvador
>  wrote:
> >
> > On Sun, Nov 25, 2018 at 7:35 PM Arnd Bergmann  wrote:
> > > On Sun, Nov 25, 2018 at 10:24 PM Otavio Salvador
> > >  wrote:
> > > >
> > > > CONFIG_ARM_UNWIND is removed when running 'savedefconfig', but
> > > > selected by the Kconfig logic.  This is done in preparation to making
> > > > further changes to this defconfig cleaner.
> > > >
> > >
> > > Does this mean we no longer get the unwinder, or there is some other
> > > config (which?) that unconditionally selects it?
> >
> > It is selected. Before changing the defconfig I did a savedefconfig to
> > avoid unrelated changes to be included on the subsequent patches and
> > then I found it was now selected.
>
> Ok, then please mention in the changelog which other option selects it,
> as I said.
>
> Aside from that, your series looks fine to me.

Thank you for reviewing it. I sent a v3 mentioning it.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854  Mobile: +1 (347) 903-9750


[PATCH v2 1/3] ARM: imx_v6_v7_defconfig: Remove explicit ARM_UNWIND disable

2018-11-25 Thread Otavio Salvador
CONFIG_ARM_UNWIND is removed when running 'savedefconfig', but
selected by the Kconfig logic.  This is done in preparation to making
further changes to this defconfig cleaner.

Reviewed-by: Fabio Estevam 
Signed-off-by: Otavio Salvador 
---

Changes in v2:
- rework commit log (Fabio Estevam)

 arch/arm/configs/imx_v6_v7_defconfig | 1 -
 1 file changed, 1 deletion(-)

diff --git a/arch/arm/configs/imx_v6_v7_defconfig 
b/arch/arm/configs/imx_v6_v7_defconfig
index aa02d18f44d1..0c887a059df3 100644
--- a/arch/arm/configs/imx_v6_v7_defconfig
+++ b/arch/arm/configs/imx_v6_v7_defconfig
@@ -445,4 +445,3 @@ CONFIG_MAGIC_SYSRQ=y
 CONFIG_PROVE_LOCKING=y
 # CONFIG_DEBUG_BUGVERBOSE is not set
 # CONFIG_FTRACE is not set
-# CONFIG_ARM_UNWIND is not set
-- 
2.19.1



[PATCH v2 2/3] ARM: imx_v6_v7_defconfig: Enable BT_BNEP

2018-11-25 Thread Otavio Salvador
From: Andreas Müller 

This is necessary to support network over bluetooth:

| Sep 11 15:36:33 imx6qdl-variscite-som bluetoothd[281]: kernel lacks 
bnep-protocol support
| Sep 11 15:36:33 imx6qdl-variscite-som bluetoothd[281]: System does not 
support network plugin

Reviewed-by: Fabio Estevam 
Signed-off-by: Andreas Müller 
Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/configs/imx_v6_v7_defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/configs/imx_v6_v7_defconfig 
b/arch/arm/configs/imx_v6_v7_defconfig
index 0c887a059df3..22ad2d7a1cf2 100644
--- a/arch/arm/configs/imx_v6_v7_defconfig
+++ b/arch/arm/configs/imx_v6_v7_defconfig
@@ -81,6 +81,7 @@ CONFIG_NETFILTER=y
 CONFIG_CAN=y
 CONFIG_CAN_FLEXCAN=y
 CONFIG_BT=y
+CONFIG_BT_BNEP=m
 CONFIG_BT_HCIUART=y
 CONFIG_BT_HCIUART_LL=y
 CONFIG_CFG80211=y
-- 
2.19.1



[PATCH v2 3/3] ARM: imx_v6_v7_defconfig: Enable USB_ANNOUNCE_NEW_DEVICES

2018-11-25 Thread Otavio Salvador
From: Andreas Müller 

This is very helpful debugging USB issues.

Reviewed-by: Fabio Estevam 
Signed-off-by: Andreas Müller 
Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/configs/imx_v6_v7_defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/configs/imx_v6_v7_defconfig 
b/arch/arm/configs/imx_v6_v7_defconfig
index 22ad2d7a1cf2..d339913845fa 100644
--- a/arch/arm/configs/imx_v6_v7_defconfig
+++ b/arch/arm/configs/imx_v6_v7_defconfig
@@ -305,6 +305,7 @@ CONFIG_SND_SOC_WM8962=y
 CONFIG_SND_SIMPLE_CARD=y
 CONFIG_HID_MULTITOUCH=y
 CONFIG_USB=y
+CONFIG_USB_ANNOUNCE_NEW_DEVICES=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_EHCI_MXC=y
 CONFIG_USB_STORAGE=y
-- 
2.19.1



[PATCH v2] ARM: dts: rv1108: enable eMMC support

2018-11-25 Thread Otavio Salvador
Enable eMMC support for rv1108.dtsi as it can be used across multiple
boards.

Signed-off-by: Otavio Salvador 
---

Changes in v2:
- rework evb device tree (Heiko Stuebner)
- avoid adding the evb use as it is not present on evb but
  minievb (which I don't have to test) and we are using it on a custom
  customer board.

 arch/arm/boot/dts/rv1108.dtsi | 21 +
 1 file changed, 21 insertions(+)

diff --git a/arch/arm/boot/dts/rv1108.dtsi b/arch/arm/boot/dts/rv1108.dtsi
index ed8f6ca52c5b..4f4275599f7a 100644
--- a/arch/arm/boot/dts/rv1108.dtsi
+++ b/arch/arm/boot/dts/rv1108.dtsi
@@ -734,6 +734,27 @@
};
};
 
+   emmc {
+   emmc_clk: emmc-clk {
+   rockchip,pins = <2 RK_PB6 RK_FUNC_1 
_pull_none_drv_8ma>;
+   };
+
+   emmc_cmd: emmc-cmd {
+   rockchip,pins = <2 RK_PB4 RK_FUNC_2 
_pull_up_drv_8ma>;
+   };
+
+   emmc_bus8: emmc-bus8 {
+   rockchip,pins = <2 RK_PA0 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA1 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA2 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA3 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA4 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA5 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA6 RK_FUNC_2 
_pull_up_drv_8ma>,
+   <2 RK_PA7 RK_FUNC_2 
_pull_up_drv_8ma>;
+   };
+   };
+
sdmmc {
sdmmc_clk: sdmmc-clk {
rockchip,pins = <3 RK_PC4 RK_FUNC_1 
_pull_none_drv_4ma>;
-- 
2.19.1



[PATCH 06/13] ARM: dts: rv1108: Add GMAC support

2018-11-25 Thread Otavio Salvador
Add GMAC support for RV1108.

Signed-off-by: Otavio Salvador 
---

 arch/arm/boot/dts/rv1108.dtsi | 36 +++
 1 file changed, 36 insertions(+)

diff --git a/arch/arm/boot/dts/rv1108.dtsi b/arch/arm/boot/dts/rv1108.dtsi
index 4f4275599f7a..c7a26f82655b 100644
--- a/arch/arm/boot/dts/rv1108.dtsi
+++ b/arch/arm/boot/dts/rv1108.dtsi
@@ -516,6 +516,27 @@
status = "disabled";
};
 
+   gmac: eth@3020 {
+   compatible = "rockchip,rv1108-gmac";
+   reg = <0x3020 0x1>;
+   rockchip,grf = <>;
+   interrupts = ,
+;
+   interrupt-names = "macirq", "eth_wake_irq";
+   clocks = < SCLK_MAC>,
+   < SCLK_MAC_RX>, < SCLK_MAC_RX>,
+   < SCLK_MAC_REF>, < SCLK_MAC_REFOUT>,
+   < ACLK_GMAC>, < PCLK_GMAC>;
+   clock-names = "stmmaceth",
+   "mac_clk_rx", "mac_clk_tx",
+   "clk_mac_ref", "clk_mac_refout",
+   "aclk_mac", "pclk_mac";
+   phy-mode = "rmii";
+   pinctrl-names = "default";
+   pinctrl-0 = <_pins>;
+   status = "disabled";
+   };
+
gic: interrupt-controller@3201 {
compatible = "arm,gic-400";
interrupt-controller;
@@ -641,6 +662,21 @@
input-enable;
};
 
+   gmac {
+   rmii_pins: rmii-pins {
+   rockchip,pins = <1 RK_PC5 RK_FUNC_2 
_pull_none>,
+   <1 RK_PC3 RK_FUNC_2 
_pull_none>,
+   <1 RK_PC4 RK_FUNC_2 
_pull_none>,
+   <1 RK_PB2 RK_FUNC_3 
_pull_none_drv_12ma>,
+   <1 RK_PB3 RK_FUNC_3 
_pull_none_drv_12ma>,
+   <1 RK_PB4 RK_FUNC_3 
_pull_none_drv_12ma>,
+   <1 RK_PB5 RK_FUNC_3 
_pull_none>,
+   <1 RK_PB6 RK_FUNC_3 
_pull_none>,
+   <1 RK_PB7 RK_FUNC_3 
_pull_none>,
+   <1 RK_PC2 RK_FUNC_3 
_pull_none>;
+   };
+   };
+
i2c0 {
i2c0_xfer: i2c0-xfer {
rockchip,pins = <0 RK_PB1 RK_FUNC_1 
_pull_none_smt>,
-- 
2.19.1



[PATCH 03/13] net: stmmac: dwmac-rk: Allow the driver to probe when phy-supply is not present

2018-11-25 Thread Otavio Salvador
The phy-supply is an optional regulator, so we should not treat
as an error when phy-supply is not passed in the device tree.

This allows the dwmac-rk driver to probe when phy-supply is not
present in the dts.

Signed-off-by: Otavio Salvador 
---

 drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c 
b/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c
index 7b923362ee55..73855622445b 100644
--- a/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c
+++ b/drivers/net/ethernet/stmicro/stmmac/dwmac-rk.c
@@ -1205,7 +1205,7 @@ static int phy_power_on(struct rk_priv_data *bsp_priv, 
bool enable)
 
if (!ldo) {
dev_err(dev, "no regulator found\n");
-   return -1;
+   return 0;
}
 
if (enable) {
-- 
2.19.1



[PATCH 02/13] ARM: multi_v7_defconfig: Add missing systemd options

2018-11-25 Thread Otavio Salvador
From: Fabio Berton 

Signed-off-by: Fabio Berton 
Signed-off-by: Otavio Salvador 
---

 arch/arm/configs/multi_v7_defconfig | 5 +
 1 file changed, 5 insertions(+)

diff --git a/arch/arm/configs/multi_v7_defconfig 
b/arch/arm/configs/multi_v7_defconfig
index a8ec309d182a..34c8a745d951 100644
--- a/arch/arm/configs/multi_v7_defconfig
+++ b/arch/arm/configs/multi_v7_defconfig
@@ -2,7 +2,12 @@ CONFIG_SYSVIPC=y
 CONFIG_NO_HZ=y
 CONFIG_HIGH_RES_TIMERS=y
 CONFIG_CGROUPS=y
+CONFIG_CGROUP_BPF=y
+CONFIG_NAMESPACES=y
+CONFIG_USER_NS=y
+CONFIG_CHECKPOINT_RESTORE=y
 CONFIG_BLK_DEV_INITRD=y
+CONFIG_BPF_SYSCALL=y
 CONFIG_EMBEDDED=y
 CONFIG_PERF_EVENTS=y
 CONFIG_MODULES=y
-- 
2.19.1



[PATCH 07/13] ARM: dts: rv1108: Fix the timer mask

2018-11-25 Thread Otavio Salvador
As done in the Rockchip vendor tree and also on other
"arm,armv7-timer" instances, the correct GIC_CPU_MASK_SIMPLE mask
is 4 instead of 1.

Signed-off-by: Otavio Salvador 
Signed-off-by: Fabio Berton 
---

 arch/arm/boot/dts/rv1108.dtsi | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/boot/dts/rv1108.dtsi b/arch/arm/boot/dts/rv1108.dtsi
index c7a26f82655b..7b331766120d 100644
--- a/arch/arm/boot/dts/rv1108.dtsi
+++ b/arch/arm/boot/dts/rv1108.dtsi
@@ -71,8 +71,8 @@
 
timer {
compatible = "arm,armv7-timer";
-   interrupts = ,
-;
+   interrupts = ,
+;
clock-frequency = <2400>;
};
 
-- 
2.19.1



Re: [PATCH v2 4/4] ARM: dts: rockchip: Add internal timer support for rv1108

2018-11-26 Thread Otavio Salvador
Hello Heiko,

On Mon, Nov 26, 2018 at 10:29 PM Heiko Stuebner  wrote:
> Am Montag, 26. November 2018, 18:35:06 CET schrieb Otavio Salvador:
> > Add support for the internal timer peripheral on RV1108.
> >
> > Signed-off-by: Otavio Salvador 
> > ---
>
> looks good, but due to the newly added compatible
> I'll let this sit a bit longer to give Rob a chance to add a
> Review-tag or so.

Sure, it is fine. Thanks for your support.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854  Mobile: +1 (347) 903-9750


Re: [PATCH 08/13] ARM: dts: rv1108: Fix the PMU interrupt number

2018-11-26 Thread Otavio Salvador
Hello Heiko,

On Mon, Nov 26, 2018 at 3:59 AM Heiko Stuebner  wrote:
> Am Sonntag, 25. November 2018, 22:19:02 CET schrieb Otavio Salvador:
> > According to the Rockchip vendor tree the PMU interrupt number is
> > 76, so fix it accordingly.
> >
> > Signed-off-by: Otavio Salvador 
> > Signed-off-by: Fabio Berton 
>
> looks ok, especially as the TRM I have doesn't list neither irqs :-)
> But please explain the second Signed-off by Fabio?
>
> If Fabio is the original author, the patch From should reflect that
> and the Signed-off-by lines should be swapped. As it is now
> I would expect Fabio being the one sending the patches.
> Or is it supposed to be a "Co-developed-by:"?
> See Documentation/process/5.Posting.rst.

He works with me and he applied and tested it in our internal tree for
our customer. He reviewed and tested this with me, so I'd like to
provide him credit as well.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854  Mobile: +1 (347) 903-9750


[PATCH v2 1/2] ARM: multi_v7_defconfig: Select PHY_ROCKCHIP_INNO_USB2

2018-11-26 Thread Otavio Salvador
Select the CONFIG_PHY_ROCKCHIP_INNO_USB2 option by default, so that
USB can be functional on RV1108.

Signed-off-by: Otavio Salvador 
---

Changes in v2: None

 arch/arm/configs/multi_v7_defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/configs/multi_v7_defconfig 
b/arch/arm/configs/multi_v7_defconfig
index 63af6234c1b6..a8ec309d182a 100644
--- a/arch/arm/configs/multi_v7_defconfig
+++ b/arch/arm/configs/multi_v7_defconfig
@@ -947,6 +947,7 @@ CONFIG_PHY_CPCAP_USB=m
 CONFIG_PHY_QCOM_APQ8064_SATA=m
 CONFIG_PHY_RCAR_GEN2=m
 CONFIG_PHY_ROCKCHIP_DP=m
+CONFIG_PHY_ROCKCHIP_INNO_USB2=y
 CONFIG_PHY_ROCKCHIP_USB=y
 CONFIG_PHY_SAMSUNG_USB2=m
 CONFIG_PHY_MIPHY28LP=y
-- 
2.19.2



[PATCH v2 2/2] ARM: multi_v7_defconfig: Improve use with systemd

2018-11-26 Thread Otavio Salvador
From: Fabio Berton 

This enables following options:

 - CONFIG_CGROUP_BPF
 - CONFIG_NAMESPACES
 - CONFIG_USER_NS
 - CONFIG_CHECKPOINT_RESTORE
 - CONFIG_BPF_SYSCALL

Those are based on recommendation from Gentoo wiki[1] which describes
the recommended and required kernel options for systemd use.

 1. https://wiki.gentoo.org/wiki/Systemd#Kernel

Signed-off-by: Fabio Berton 
Signed-off-by: Otavio Salvador 
---

Changes in v2:
- rework commit log

 arch/arm/configs/multi_v7_defconfig | 5 +
 1 file changed, 5 insertions(+)

diff --git a/arch/arm/configs/multi_v7_defconfig 
b/arch/arm/configs/multi_v7_defconfig
index a8ec309d182a..34c8a745d951 100644
--- a/arch/arm/configs/multi_v7_defconfig
+++ b/arch/arm/configs/multi_v7_defconfig
@@ -2,7 +2,12 @@ CONFIG_SYSVIPC=y
 CONFIG_NO_HZ=y
 CONFIG_HIGH_RES_TIMERS=y
 CONFIG_CGROUPS=y
+CONFIG_CGROUP_BPF=y
+CONFIG_NAMESPACES=y
+CONFIG_USER_NS=y
+CONFIG_CHECKPOINT_RESTORE=y
 CONFIG_BLK_DEV_INITRD=y
+CONFIG_BPF_SYSCALL=y
 CONFIG_EMBEDDED=y
 CONFIG_PERF_EVENTS=y
 CONFIG_MODULES=y
-- 
2.19.2



Re: [PATCH 07/13] ARM: dts: rv1108: Fix the timer mask

2018-11-26 Thread Otavio Salvador
On Mon, Nov 26, 2018 at 3:27 AM Heiko Stuebner  wrote:
> Am Sonntag, 25. November 2018, 22:19:01 CET schrieb Otavio Salvador:
> > As done in the Rockchip vendor tree and also on other
> > "arm,armv7-timer" instances, the correct GIC_CPU_MASK_SIMPLE mask
> > is 4 instead of 1.
>
> Nope. That value represents the number of cores in the system.
> As the rv1108 only has one core, that should likely stay as it is.

I see, I will drop it for v2.

> Also, it seems I only got patches 6-13 what happened to 1-5?

It went to other mailing lists, I think. I will add you on Cc to all for v2.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9 9981-7854  Mobile: +1 (347) 903-9750


  1   2   3   >