title: How can I discard modified files?
body: <p>This is a Linux 2.6 kernel repository. I git clone it to my local host.</p>
  
  <p>After that. I didn't make any change. But when I "git status". I found 13 modified files. I want to discard them, but I can't.</p>
  
  <pre><code>&gt; luke@Macbook-Pro~/Documents/workspace/linuxkernel/linux-2.6$ git
  &gt; status
  &gt; # On branch master
  &gt; # Changes not staged for commit:
  &gt; #   (use "git add &lt;file&gt;..." to update what will be committed)
  &gt; #   (use "git checkout -- &lt;file&gt;..." to discard changes in working directory)
  &gt; #
  &gt; # modified:   include/linux/netfilter/xt_connmark.h
  &gt; # modified:   include/linux/netfilter/xt_dscp.h
  &gt; # modified:   include/linux/netfilter/xt_mark.h
  &gt; # modified:   include/linux/netfilter/xt_rateest.h
  &gt; # modified:   include/linux/netfilter/xt_tcpmss.h
  &gt; # modified:   include/linux/netfilter_ipv4/ipt_ecn.h
  &gt; # modified:   include/linux/netfilter_ipv4/ipt_ttl.h
  &gt; # modified:   include/linux/netfilter_ipv6/ip6t_hl.h
  &gt; # modified:   net/ipv4/netfilter/ipt_ecn.c
  &gt; # modified:   net/netfilter/xt_dscp.c
  &gt; # modified:   net/netfilter/xt_hl.c
  &gt; # modified:   net/netfilter/xt_rateest.c
  &gt; # modified:   net/netfilter/xt_tcpmss.c
  &gt; #
  &gt; # Untracked files:
  &gt; #   (use "git add &lt;file&gt;..." to include in what will be committed)
  &gt; #
  &gt; # samples/hidraw/ no changes added to commit (use "git add" and/or "git commit -a")
  &gt; luke@Macbook-Pro~/Documents/workspace/linuxkernel/linux-2.6$ git
  &gt; checkout -- include/linux/netfilter/xt_connmark. h
  &gt; luke@Macbook-Pro~/Documents/workspace/linuxkernel/linux-2.6$ git
  &gt; status
  &gt; # On branch master
  &gt; # Changes not staged for commit:
  &gt; #   (use "git add &lt;file&gt;..." to update what will be committed)
  &gt; #   (use "git checkout -- &lt;file&gt;..." to discard changes in working directory)
  &gt; #
  &gt; # modified:   include/linux/netfilter/xt_CONNMARK.h
  &gt; # modified:   include/linux/netfilter/xt_dscp.h
  &gt; # modified:   include/linux/netfilter/xt_mark.h
  &gt; # modified:   include/linux/netfilter/xt_rateest.h
  &gt; # modified:   include/linux/netfilter/xt_tcpmss.h
  &gt; # modified:   include/linux/netfilter_ipv4/ipt_ecn.h
  &gt; # modified:   include/linux/netfilter_ipv4/ipt_ttl.h
  &gt; # modified:   include/linux/netfilter_ipv6/ip6t_hl.h
  &gt; # modified:   net/ipv4/netfilter/ipt_ecn.c
  &gt; # modified:   net/netfilter/xt_dscp.c
  &gt; # modified:   net/netfilter/xt_hl.c
  &gt; # modified:   net/netfilter/xt_rateest.c
  &gt; # modified:   net/netfilter/xt_tcpmss.c
  &gt; #
  &gt; # Untracked files:
  &gt; #   (use "git add &lt;file&gt;..." to include in what will be committed)
  &gt; #
  &gt; # samples/hidraw/ no changes added to commit (use "git add" and/or "git commit -a")
  &gt; luke@Macbook-Pro~/Documents/workspace/linuxkernel/linux-2.6$ git
  &gt; checkout -- include/linux/netfilter/xt_dscp.h
  &gt; luke@Macbook-Pro~/Documents/workspace/linuxkernel/linux-2.6$ git
  &gt; status
  &gt; # On branch master
  &gt; # Changes not staged for commit:
  &gt; #   (use "git add &lt;file&gt;..." to update what will be committed)
  &gt; #   (use "git checkout -- &lt;file&gt;..." to discard changes in working directory)
  &gt; #
  &gt; # modified:   include/linux/netfilter/xt_CONNMARK.h
  &gt; # modified:   include/linux/netfilter/xt_DSCP.h
  &gt; # modified:   include/linux/netfilter/xt_mark.h
  &gt; # modified:   include/linux/netfilter/xt_rateest.h
  &gt; # modified:   include/linux/netfilter/xt_tcpmss.h
  &gt; # modified:   include/linux/netfilter_ipv4/ipt_ecn.h
  &gt; # modified:   include/linux/netfilter_ipv4/ipt_ttl.h
  &gt; # modified:   include/linux/netfilter_ipv6/ip6t_hl.h
  &gt; # modified:   net/ipv4/netfilter/ipt_ecn.c
  &gt; # modified:   net/netfilter/xt_dscp.c
  &gt; # modified:   net/netfilter/xt_hl.c
  &gt; # modified:   net/netfilter/xt_rateest.c
  &gt; # modified:   net/netfilter/xt_tcpmss.c
  &gt; #
  &gt; # Untracked files:
  &gt; #   (use "git add &lt;file&gt;..." to include in what will be committed)
  &gt; #
  &gt; # samples/hidraw/ no changes added to commit (use "git add" and/or "git commit -a")
  &gt; luke@Macbook-Pro~/Documents/workspace/linuxkernel/linux-2.6$ 
  &gt; 
  </code></pre>
  
  <p>edited:</p>
  
  <pre><code>luke@Macbook-Pro~/Documents/workspace/linuxkernel/linux-2.6$ git config -l
  user.name=99999
  user.email=99999
  alias.co=checkout
  core.editor=mate -w
  core.edit=mate -w
  core.excludesfile=/Users/luke/.gitignore_global
  difftool.sourcetree.cmd=opendiff "$LOCAL" "$REMOTE"
  difftool.sourcetree.path=
  mergetool.sourcetree.cmd=/Applications/SourceTree.app/Contents/Resources/opendiff-w.sh "$LOCAL" "$REMOTE" -ancestor "$BASE" -merge "$MERGED"
  mergetool.sourcetree.trustexitcode=true
  core.repositoryformatversion=0
  core.filemode=true
  core.bare=false
  core.logallrefupdates=true
  core.ignorecase=true
  </code></pre>
  
  <p>edited: this is my diff file:</p>
  
  <pre><code>diff --git a/include/linux/netfilter/xt_CONNMARK.h b/include/linux/netfilter/xt_CONNMARK.h
  index 2f2e48e..efc17a8 100644
  --- a/include/linux/netfilter/xt_CONNMARK.h
  +++ b/include/linux/netfilter/xt_CONNMARK.h
  @@ -1,6 +1,31 @@
  -#ifndef _XT_CONNMARK_H_target
  -#define _XT_CONNMARK_H_target
  +#ifndef _XT_CONNMARK_H
  +#define _XT_CONNMARK_H
  
  -#include &lt;linux/netfilter/xt_connmark.h&gt;
  +#include &lt;linux/types.h&gt;
  
  -#endif /*_XT_CONNMARK_H_target*/
  +/* Copyright (C) 2002,2004 MARA Systems AB &lt;http://www.marasystems.com&gt;
  + * by Henrik Nordstrom &lt;hno@marasystems.com&gt;
  + *
  + * This program 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.
  + */
  +
  +enum {
  +   XT_CONNMARK_SET = 0,
  +   XT_CONNMARK_SAVE,
  +   XT_CONNMARK_RESTORE
  +};
  +
  +struct xt_connmark_tginfo1 {
  +   __u32 ctmark, ctmask, nfmask;
  +   __u8 mode;
  +};
  +
  +struct xt_connmark_mtinfo1 {
  +   __u32 mark, mask;
  +   __u8 invert;
  +};
  +
  +#endif /*_XT_CONNMARK_H*/
  diff --git a/include/linux/netfilter/xt_DSCP.h b/include/linux/netfilter/xt_DSCP.h
  index 648e0b3..15f8932 100644
  --- a/include/linux/netfilter/xt_DSCP.h
  +++ b/include/linux/netfilter/xt_DSCP.h
  @@ -1,26 +1,31 @@
  -/* x_tables module for setting the IPv4/IPv6 DSCP field
  +/* x_tables module for matching the IPv4/IPv6 DSCP field
    *
    * (C) 2002 Harald Welte &lt;laforge@gnumonks.org&gt;
  - * based on ipt_FTOS.c (C) 2000 by Matthew G. Marsh &lt;mgm@paktronix.com&gt;
    * This software is distributed under GNU GPL v2, 1991
    *
    * See RFC2474 for a description of the DSCP field within the IP Header.
    *
  - * xt_DSCP.h,v 1.7 2002/03/14 12:03:13 laforge Exp
  + * xt_dscp.h,v 1.3 2002/08/05 19:00:21 laforge Exp
   */
  -#ifndef _XT_DSCP_TARGET_H
  -#define _XT_DSCP_TARGET_H
  -#include &lt;linux/netfilter/xt_dscp.h&gt;
  +#ifndef _XT_DSCP_H
  +#define _XT_DSCP_H
  +
   #include &lt;linux/types.h&gt;
  
  -/* target info */
  -struct xt_DSCP_info {
  +#define XT_DSCP_MASK   0xfc    /* 11111100 */
  +#define XT_DSCP_SHIFT  2
  +#define XT_DSCP_MAX    0x3f    /* 00111111 */
  +
  +/* match info */
  +struct xt_dscp_info {
      __u8 dscp;
  +   __u8 invert;
   };
  
  -struct xt_tos_target_info {
  -   __u8 tos_value;
  +struct xt_tos_match_info {
      __u8 tos_mask;
  +   __u8 tos_value;
  +   __u8 invert;
   };
  
  -#endif /* _XT_DSCP_TARGET_H */
  +#endif /* _XT_DSCP_H */
  diff --git a/include/linux/netfilter/xt_mark.h b/include/linux/netfilter/xt_mark.h
  index ecadc40..41c456d 100644
  --- a/include/linux/netfilter/xt_mark.h
  +++ b/include/linux/netfilter/xt_mark.h
  @@ -1,15 +1,6 @@
  -#ifndef _XT_MARK_H
  -#define _XT_MARK_H
  +#ifndef _XT_MARK_H_target
  +#define _XT_MARK_H_target
  
  -#include &lt;linux/types.h&gt;
  +#include &lt;linux/netfilter/xt_mark.h&gt;
  
  -struct xt_mark_tginfo2 {
  -   __u32 mark, mask;
  -};
  -
  -struct xt_mark_mtinfo1 {
  -   __u32 mark, mask;
  -   __u8 invert;
  -};
  -
  -#endif /*_XT_MARK_H*/
  +#endif /*_XT_MARK_H_target */
  diff --git a/include/linux/netfilter/xt_rateest.h b/include/linux/netfilter/xt_rateest.h
  index d40a619..6605e20 100644
  --- a/include/linux/netfilter/xt_rateest.h
  +++ b/include/linux/netfilter/xt_rateest.h
  @@ -1,37 +1,15 @@
  -#ifndef _XT_RATEEST_MATCH_H
  -#define _XT_RATEEST_MATCH_H
  +#ifndef _XT_RATEEST_TARGET_H
  +#define _XT_RATEEST_TARGET_H
  </code></pre>
  
  <p>Due to Stack Overflow length limit. Only part of diff file can be copied here.</p>
  
  <p>still need help</p>