LTIB: how applying a patch?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LTIB: how applying a patch?

2,792 Views
madmax
Contributor I

I'm a novice to Linux embedded and LTIB, and I'm evaluating the i.MX53 QSB with Freescale Linux BSP. After downloading and extracting the L2.6.35_11.09.01_source_bundle.tar.gz contents, I got:

- L2.6.35_11.09.01_ER_docs.tar.gz

- L2.6.35_11.09.01_ER_images_MX5X.tar.gz

- L2.6.35_11.09.01_ER_source.tar.gz

as described in the "i.MX53 START 11.09.01 Linux Release Notes.pdf" document. But that BSP also included:

- patches.tar.gz

 

I installed ltib and setup my Ubuntu machine following all steps described in the "i.MX53 START Linux User’s Guide.pdf", chapter 2. Only skipped the step #3, in chapter 2.2: "Install the patches located in the patches.tar.gz file"... It wasn't explained how.

 

Since some days I can compile the kernel and u-boot, generate the target file system, and run my "helloworld" on the i.mX53 target after cross-compiling.... but the 'patches issue' is still pending, and want to fix it before proceeding!

I searched around but haven't found a way for patching a package in ltib. Only found how patching my changes (eventually) with 'patchmerge' ltib command. But spec file seems to be required, and patches in the Freescale BSP only have .patch.

 

May you experts give me some help?!

Thank you

Tags (1)
0 Kudos
Reply
3 Replies

1,149 Views
KrishnaPavan
Contributor II

Hi all,

 

It can also be cat patch_name | patch -p2.

I am working on a different board.

0 Kudos
Reply

1,149 Views
madmax
Contributor I

Hi Terence,

 

that's exactly what tried yesterday after asking the question, and taking the 'U-Boot Patches' paragraph in this page as an example:

http://www.eewiki.net/display/linuxonarm/i.MX53+Quick+Start

However it must unpacks all packages to be patched before, with command

$ ./ltib -m prep -p <package_to_be_patched>

with <package_to_be_patched> = 'imx_test', 'u-boot'....

 

It seems working, but there's maybe a better way directly from ltib commands.

 

Thank you

Massimo

 


Terence Soh said:

Hi Massimo,

 

I have also struggled with this. What I did was to configure and compile the ltib first with the source code in place.

- ltib -m config

- ltib --leavesrc

 

After compilation, I cd to ltib/rpm/BUILD and patched the files into the kernel, u-boot and imx-test.

$ patch -p1 < 0001-ENGR00155891-mx53_loco-enable-mc34708-s-WDI-function.patch 
patching file arch/arm/mach-mx5/mx53_loco_pmic_mc34708.c
patching file arch/arm/plat-mxc/system.c
soht1@leonine:/data/nfsroot/ltib/ltib/rpm/BUILD/linux-2.6.35.3$ patch -p1 < 0001-Fix-the-ack-error-when-read-system-s-temperature-on-.patch 
patching file arch/arm/plat-mxc/ahci_sata.c

If someone has a better way, please let us know.

 

Terence

0 Kudos
Reply

1,149 Views
TerenceSoh
Contributor I

Hi Massimo,

 

I have also struggled with this. What I did was to configure and compile the ltib first with the source code in place.

- ltib -m config

- ltib --leavesrc

 

After compilation, I cd to ltib/rpm/BUILD and patched the files into the kernel, u-boot and imx-test.

$ patch -p1 < 0001-ENGR00155891-mx53_loco-enable-mc34708-s-WDI-function.patch 
patching file arch/arm/mach-mx5/mx53_loco_pmic_mc34708.c
patching file arch/arm/plat-mxc/system.c
soht1@leonine:/data/nfsroot/ltib/ltib/rpm/BUILD/linux-2.6.35.3$ patch -p1 < 0001-Fix-the-ack-error-when-read-system-s-temperature-on-.patch 
patching file arch/arm/plat-mxc/ahci_sata.c

If someone has a better way, please let us know.

 

Terence

0 Kudos
Reply