DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD Installation and Upgrading

OpenBSD Installation and Upgrading Installing and upgrading OpenBSD.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 18th May 2011
darshadow darshadow is offline
New User
 
Join Date: May 2011
Posts: 2
Default How apply diff patch...

Hi,
I've installed OpenBSD 4.9 on a Netbook AOD255E and for resolve the problem with my Ethernet Card I should to install
a new patch diff : "http://marc.info/?l=openbsd-tech&m=129595134124076&w=2"
So, I'm newbie and need some help to known in which way to do that :
-Should I copy all content between two Index: share/man/man4/alc.4 text from the RCS line "RCS file: /cvs/src/share/man/man4/alc.4,v" until the next index and paste it in a file name /cvs/src/share/man/man4/alc.4 ?
-Then the following :
Code:
# cd /cvs/src/share/man/man4/
# patch -p0 < 001_st.patch (with the name of patch) alc.4
Yeah, I don't known it seems only manpages ???
and rebuild the kernel, like : "http://www.openbsd.org/faq/faq5.html#BldKernel"

I've just checked google and some openbsd faq, but in the beginning is hard to find quickly to right infos.

Any help will be appreciated,
Best regards
Reply With Quote
  #2   (View Single Post)  
Old 18th May 2011
ocicat ocicat is offline
Administrator
 
Join Date: Apr 2008
Posts: 3,318
Default

Quote:
Originally Posted by darshadow View Post
I've installed OpenBSD 4.9 on a Netbook AOD255E and for resolve the problem with my Ethernet Card I should to install
a new patch diff : "http://marc.info/?l=openbsd-tech&m=129595134124076&w=2"
diff(1) output posted to the tech@ mailing list is expected to be patched against -current. If you installed OpenBSD 4.9-release, you may well create an unstable or non-functioning system. Officially, the project would not support such a mixture of different versions.

If you are unclear as to the differences between -release & -current, study Section 5.1 of the FAQ.

Patching is discussed in Section 10.15 of the FAQ.

If you have an interface using the alc(4) driver & wish to see if newer code resolves any issues, install a snapshot of -current first. At that point, you can decide whether you want to apply any diffs found on tech@.

Lastly, the diff mentioned in your link above is dated January 2011 & affects the CVS version 1.8 of src/sys/dev/pci/if_alc.c. This diff is quite old, & may or may not apply as expected given that the most recent version is 1.12.

There has been more recent discussion regarding this interface on tech@:

http://marc.info/?l=openbsd-tech&w=2&r=1&s=alc&q=b

My suggestion would be to study more recent discussion before installing a snapshot of -current if you feel newer code may be worth testing. After installing -current, you will have a platform in which you can test diff's posted to tech@ if you so choose.

Last edited by ocicat; 18th May 2011 at 08:14 PM.
Reply With Quote
  #3   (View Single Post)  
Old 18th May 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Banned
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Default

That is a patch to a man page, if you don't comprehend the concept of source code.. you should not be using OpenBSD.
Reply With Quote
  #4   (View Single Post)  
Old 18th May 2011
ocicat ocicat is offline
Administrator
 
Join Date: Apr 2008
Posts: 3,318
Default

Quote:
Originally Posted by BSDfan666 View Post
That is a patch to a man page...
Patching the alc(4) manpage is only one of several files patched by the diff.
Reply With Quote
  #5   (View Single Post)  
Old 18th May 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Banned
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Default

For adding support for the controller, patching the man page is a very low priority.. this person has also posted on the mailing lists a similar ignorance of how things work, focusing a lot of "alc.4" which is a very irrelevant part of the diff.

I'd recommend that the OP take some time to read the diff, among other things.
Reply With Quote
  #6   (View Single Post)  
Old 19th May 2011
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,975
Default

I'm confused. I think this has gone way off-topic.

First, the patch revises the man page, inline documentation in kernel configurations (GENERIC and RAMDISK_CD for both i386 and amd64), inline doc for sys/dev/pci/files.pci, and then, finally, makes significant functionality additions to sys/dev/pci/if_alc.c and then supporting variable changes to sys/dev/pci/if_alcreg.h.

-----
With that out of the way...

The functional patch to if_alc.c was against version 1.8. The 4.9-release version of if_alc.c is version 1.10. This patch was created prior to 4.9-release.

Not only that...

This patch was fitted to -current and committed to the OpenBSD source tree approximately 22 hours ago, as version 1.12.

A snapshot built later today or tomorrow will include it. A build of -current from a freshly updated source tree will include it.
Reply With Quote
  #7   (View Single Post)  
Old 19th May 2011
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,975
Default

Some additional information OpenBSD admins need to know, that may not be obvious from my previous posting:
  • OpenBSD is source code maintained. To make changes to OpenBSD source code, an admin needs to understand the tools used for managing OpenBSD source: cvs(1), diff(1), and patch(1). The OpenBSD Project uses unified diffs only, by the way: diff -u is mandatory when creating patch files.
  • OpenBSD admins need to understand the flavors of OpenBSD, the release lifecycle, and how cvs is used to manage these. A cvs log for an individual file must be understandable: the revision history and associated tags need to be understood.
  • Any patch which is to be applied to a different source code version will likely require manual integration. In this case, Darshadow would likely have to revise the patch to be able to apply it to 4.9-release, since it was developed against 4.8-current.
Understanding FAQ 5 is also a necessity.
Reply With Quote
  #8   (View Single Post)  
Old 24th May 2011
darshadow darshadow is offline
New User
 
Join Date: May 2011
Posts: 2
Default

All your messages were useful to me! After reading FAQs, man pages for some command and many other things in openbsd.org I understood a little more so that I could apply the patch.

Thanks a lot for your help!
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Apply TTYS changes with out reboot jjjustjjjay OpenBSD General 1 6th May 2010 09:24 PM
Patch question Mr-Biscuit Off-Topic 6 4th May 2010 07:47 PM
Patch for libXemu-1.0.3,1 mjj FreeBSD Installation and Upgrading 1 3rd January 2010 09:47 PM
run same command many times with diff args gosha Programming 21 30th May 2009 11:51 AM
How to apply patche for NMAP sniper007 FreeBSD Ports and Packages 3 27th January 2009 04:25 PM


All times are GMT. The time now is 07:08 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick