lkml.org 
[lkml]   [2012]   [Sep]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[ 121/218] NFS: Fix a problem with the legacy binary mount code
    Date
    3.4-stable review patch.  If anyone has any objections, please let me know.

    ------------------

    From: Trond Myklebust <Trond.Myklebust@netapp.com>

    commit 872ece86ea5c367aa92f44689c2d01a1c767aeb3 upstream.

    Apparently, am-utils is still using the legacy binary mountdata interface,
    and is having trouble parsing /proc/mounts due to the 'port=' field being
    incorrectly set.

    The following patch should fix up the regression.

    Reported-by: Marius Tolzmann <tolzmann@molgen.mpg.de>
    Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
    Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

    ---
    fs/nfs/super.c | 2 ++
    1 file changed, 2 insertions(+)

    --- a/fs/nfs/super.c
    +++ b/fs/nfs/super.c
    @@ -1886,6 +1886,7 @@ static int nfs_validate_mount_data(void

    memcpy(sap, &data->addr, sizeof(data->addr));
    args->nfs_server.addrlen = sizeof(data->addr);
    + args->nfs_server.port = ntohs(data->addr.sin_port);
    if (!nfs_verify_server_address(sap))
    goto out_no_address;

    @@ -2598,6 +2599,7 @@ static int nfs4_validate_mount_data(void
    return -EFAULT;
    if (!nfs_verify_server_address(sap))
    goto out_no_address;
    + args->nfs_server.port = ntohs(((struct sockaddr_in *)sap)->sin_port);

    if (data->auth_flavourlen) {
    if (data->auth_flavourlen > 1)



    \
     
     \ /
      Last update: 2012-09-29 00:21    [W:5.240 / U:0.176 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site