1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to create a mfi patch on FreeBSD

Discussion in 'FreeBSD Development' started by linuxunix, Dec 2, 2011.

  1. linuxunix

    linuxunix New Member

    Thanks Received:
    Hi guys,

    I have a patch downloaded from LSI related to mfi. The old mfi path is /usr/src/sys/dev/mfi and I have placed new mfi at /usr/src/sys/dev/mfi.new.

    How shall I create a patch out of this:

    I tried creating a patch file as shown below:
    freebsdd#diff -crB /usr/src/sys/dev/mfi/ /usr/src/sys/dev/mfi.new/ > working.patch

    Went through dry-run
    freebss# patch --check -p1 -i working.patch
    Hmm...  Looks like a new-style context diff to me...
    The text leading up to this was:
    |Only in /usr/src/sys/dev/mfi.new/: Makefile
    |Only in /usr/src/sys/dev/mfi.new/: Readme.doc
    |diff -crB /usr/src/sys/dev/mfi/mfi.c /usr/src/sys/dev/mfi.new/mfi.c
    |*** /usr/src/sys/dev/mfi/mfi.c Mon Jun 14 07:39:06 2010
    |--- /usr/src/sys/dev/mfi.new/mfi.c     Mon Nov 28 23:07:15 2011
    File to patch: /usr/src/sys/dev/mfi
    patch: **** /usr/src/sys/dev/mfi is not a normal file--can't patch

    Am I doing right?
  2. mix_room

    mix_room Member

    Thanks Received:
    It looks like you are trying to patch a directory. Try cd-ing to the directory and have a look what is inside.