29 Jan, 2018

1 commit


22 Jan, 2018

1 commit


23 Nov, 2017

1 commit


14 Sep, 2017

1 commit

  • This section of the settings file may be missing. Handle that gracefully
    rather than emitting an error.

    Also update patman to write this section when a new settings file is
    created.

    Fixes: e11aa602 (patman: add support for omitting bouncing addresses)

    Signed-off-by: Simon Glass
    Reviewed-by: Chris Packham
    Tested-by: Bin Meng

    Simon Glass
     

12 Sep, 2017

1 commit


09 Jun, 2017

10 commits

  • The existing test (patman --test) only covers basic checkpatch output.
    We have had some problems with unicode processing and could use test
    coverage for the various tags patman supports.

    Add a new functional test which runs most of the patman flow on a few
    test commits and checks that the results are correct.

    See the documentation in the test for a description of what it does.

    Signed-off-by: Simon Glass
    Tested-by: Philipp Tomsich

    Simon Glass
     
  • This is not a good variable name in Python because 'list' is a type. It
    shows up highlighted in some editors. Rename it.

    Signed-off-by: Simon Glass
    Tested-by: Philipp Tomsich

    Simon Glass
     
  • Allow the add_maintainers parameter to be a list of maintainers, thus
    allowing us to simulate calling the script in tests without actually
    needing it to work.

    Signed-off-by: Simon Glass
    Tested-by: Philipp Tomsich

    Simon Glass
     
  • Add some unicode to the test patches to make sure that patman does the
    right thing.

    Signed-off-by: Simon Glass
    Tested-by: Philipp Tomsich

    Simon Glass
     
  • There is no need for this function to return the same object that was
    passed in. Drop the return value.

    Signed-off-by: Simon Glass
    Tested-by: Philipp Tomsich

    Simon Glass
     
  • Unicode characters may appear in input patches so we should not warn about
    them. Drop this warning.

    Signed-off-by: Simon Glass
    Tested-by: Philipp Tomsich

    Simon Glass
     
  • This is not a good variable name in Python because 'str' is a type. It
    shows up highlighted in some editors. Rename it.

    Signed-off-by: Simon Glass
    Tested-by: Philipp Tomsich

    Simon Glass
     
  • The communication filter reads data in blocks and converts each block to
    unicode (if necessary) one at a time. In the unlikely event that a unicode
    character in the input spans a block this will not work. We get an error
    like:

    UnicodeDecodeError: 'utf8' codec can't decode bytes in position 1022-1023:
    unexpected end of data

    There is no need to change the input to unicode, so the easiest fix is to
    drop this feature.

    Signed-off-by: Simon Glass
    Tested-by: Philipp Tomsich

    Simon Glass
     
  • Don't mess with the email address when outputting them. Just make sure
    they are encoded with utf-8.

    Signed-off-by: Simon Glass
    Tested-by: Philipp Tomsich

    Simon Glass
     
  • This change encodes the CC list to UTF-8 to avoid failures on
    maintainer-addresses that include non-ASCII characters (observed on
    Debian 7.11 with Python 2.7.3).

    Without this, I get the following failure:
    Traceback (most recent call last):
    File "tools/patman/patman", line 159, in
    options.add_maintainers)
    File "[snip]/u-boot/tools/patman/series.py", line 234, in MakeCcFile
    print(commit.patch, ', '.join(set(list)), file=fd)
    UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position 81: ordinal not in range(128)
    from Heiko's email address:
    [..., u'"Heiko St\xfcbner" ', ...]

    While with this change added this encodes to:
    "=?UTF-8?q?Heiko=20St=C3=BCbner?= "

    Signed-off-by: Philipp Tomsich
    Reviewed-by: Simon Glass
    Signed-off-by: Simon Glass
    Tested-by: Simon Glass
    Tested-by: Philipp Tomsich

    Philipp Tomsich
     

14 Apr, 2017

1 commit

  • os.read() returns a byte array in Python 3.5.2 and needs to be converted
    into a string. Check if the returned value is an instance of bytes and
    if it is decode it as a utf-8 string. If it is not a utf-8 encoded string
    the decoding may fail with an exception.

    Prior to this fix the comparisions check data == "" would fail when data
    was b'' and would cause an infinite memory leaking loop. joins would
    also fail with an exception below but due to the infinite loop it never
    made it that far.

    Signed-off-by: George McCollister
    Acked-by: Simon Glass

    George McCollister
     

08 Feb, 2017

2 commits


09 Oct, 2016

7 commits


19 Sep, 2016

3 commits


12 Jul, 2016

5 commits


18 Mar, 2016

1 commit


15 Mar, 2016

2 commits


25 Feb, 2016

1 commit

  • A patman series with a 'Series-notes' section causes
    buildman to crash with:

    self.series.notes += self.section
    TypeError: cannot concatenate 'str' and 'list' objects

    Fix by initializing series.notes as a one-element array
    rather than a scalar.

    Signed-off-by: Albert ARIBAUD
    Acked-by: Simon Glass
    Tested-by: Simon Glass

    Albert ARIBAUD
     

06 Feb, 2016

1 commit

  • Correct spelling of "U-Boot" shall be used in all written text
    (documentation, comments in source files etc.).

    Signed-off-by: Bin Meng
    Reviewed-by: Heiko Schocher
    Reviewed-by: Simon Glass
    Reviewed-by: Minkyu Kang

    Bin Meng
     

21 Jan, 2016

1 commit

  • Add option to create threaded series of patches.
    With it, it will be possible to create patch threads like this:
    [PATCH 0/10] Add support for time travel
    [PATCH 1/10] Add Flux Capacitor driver
    [PATCH 2/10] Add Mr. Fusion driver
    (...)

    Internally it will call git send-email with --thread option

    Signed-off-by: Mateusz Kulikowski
    Acked-by: Simon Glass

    Mateusz Kulikowski
     

09 Sep, 2015

1 commit

  • This reverts commit 19b4a3369876f9215e2b861f211e8df1a75e26ca.

    Since that commit, patman generates useless patches for file removal;
    "git format -D" prints only the header but not the diff when deleting
    files, and "git am" always refuses such patches.

    The following is the quotation from "man git-format-patch":

    -D, --irreversible-delete
    Omit the preimage for deletes, i.e. print only the header but
    not the diff between the preimage and /dev/null. The resulting
    patch is not meant to be applied with patch nor git apply; this
    is solely for people who want to just concentrate on reviewing
    the text after the change. In addition, the output obviously
    lack enough information to apply such a patch in reverse, even
    manually, hence the name of the option.

    Signed-off-by: Masahiro Yamada
    Acked-by: Simon Glass

    Masahiro Yamada