From patchwork Wed Sep 5 13:57:53 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeff Layton X-Patchwork-Id: 1409601 Return-Path: X-Original-To: patchwork-cifs-client@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 87E07DF28C for ; Wed, 5 Sep 2012 13:58:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751674Ab2IEN57 (ORCPT ); Wed, 5 Sep 2012 09:57:59 -0400 Received: from mail-qc0-f174.google.com ([209.85.216.174]:62057 "EHLO mail-qc0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751336Ab2IEN56 (ORCPT ); Wed, 5 Sep 2012 09:57:58 -0400 Received: by mail-qc0-f174.google.com with SMTP id o28so74407qcr.19 for ; Wed, 05 Sep 2012 06:57:58 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:x-mailer :x-gm-message-state; bh=bC38+lx1kewsQ3lkoqNXRIrzKCkjan35S4pYv8/CvFg=; b=UO2olMMqqTDgOEt6ELrLAGiCS3LbLYciQCmS5XZLyO/IRp9CPSpFbr0h0Tqtf7TI+7 gnVN8KQXtzETtkJTN4wvitWihcUvQsu9QRcnX69Mb7S3lDhmiS9ZiP0NcmqOh0pk35TW qIpt2NITnEHEhCU9mklfvB06/P7WSkvy4NHL3ryohidMjJoNSOSc/0TQ2yP8DhCSuCoT qv7CYORU2UYiRGfbvJxNtBQud2FPJYGZYSzhoD0YPUsGv2J5ldo3IZoKrRcEQ4zFgyVn /XJ//IpBPfCBXqBBI2ybRAPbDbL8NkT3hasgQHwKcgKXjsS0QmIV/G+TMLFXeyT40o86 4z+A== Received: by 10.224.208.73 with SMTP id gb9mr44945741qab.53.1346853478262; Wed, 05 Sep 2012 06:57:58 -0700 (PDT) Received: from salusa.poochiereds.net (cpe-069-134-145-027.nc.res.rr.com. [69.134.145.27]) by mx.google.com with ESMTPS id m4sm767259qak.6.2012.09.05.06.57.57 (version=SSLv3 cipher=OTHER); Wed, 05 Sep 2012 06:57:57 -0700 (PDT) From: Jeff Layton To: smfrench@gmail.com Cc: linux-cifs@vger.kernel.org, piastryyy@gmail.com Subject: [PATCH] cifs: remove support for deprecated "forcedirectio" and "strictcache" mount options Date: Wed, 5 Sep 2012 09:57:53 -0400 Message-Id: <1346853473-13383-1-git-send-email-jlayton@redhat.com> X-Mailer: git-send-email 1.7.11.4 X-Gm-Message-State: ALoCoQnT3jndE53lUzeWNNQlzouEI5GgJ71oHeL5IZ/FBWamTlgxZcLzAMpgnkGwQn7H7iRY8bpG Sender: linux-cifs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-cifs@vger.kernel.org ...and make the default cache=strict as promised for 3.7. Signed-off-by: Jeff Layton Reviewed-by: Pavel Shilovsky --- fs/cifs/connect.c | 37 ++++--------------------------------- 1 file changed, 4 insertions(+), 33 deletions(-) diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c index 59c595e..a792282 100644 --- a/fs/cifs/connect.c +++ b/fs/cifs/connect.c @@ -82,8 +82,7 @@ enum { Opt_serverino, Opt_noserverino, Opt_rwpidforward, Opt_cifsacl, Opt_nocifsacl, Opt_acl, Opt_noacl, Opt_locallease, - Opt_sign, Opt_seal, Opt_direct, - Opt_strictcache, Opt_noac, + Opt_sign, Opt_seal, Opt_noac, Opt_fsc, Opt_mfsymlinks, Opt_multiuser, Opt_sloppy, @@ -160,10 +159,6 @@ static const match_table_t cifs_mount_option_tokens = { { Opt_locallease, "locallease" }, { Opt_sign, "sign" }, { Opt_seal, "seal" }, - { Opt_direct, "direct" }, - { Opt_direct, "directio" }, - { Opt_direct, "forcedirectio" }, - { Opt_strictcache, "strictcache" }, { Opt_noac, "noac" }, { Opt_fsc, "fsc" }, { Opt_mfsymlinks, "mfsymlinks" }, @@ -1105,8 +1100,6 @@ cifs_parse_mount_options(const char *mountdata, const char *devname, char *string = NULL; char *tmp_end, *value; char delim; - bool cache_specified = false; - static bool cache_warned = false; separator[0] = ','; separator[1] = 0; @@ -1138,6 +1131,9 @@ cifs_parse_mount_options(const char *mountdata, const char *devname, /* default to using server inode numbers where available */ vol->server_ino = 1; + /* default is to use strict cifs caching semantics */ + vol->strict_io = true; + vol->actimeo = CIFS_DEF_ACTIMEO; /* FIXME: add autonegotiation -- for now, SMB1 is default */ @@ -1321,22 +1317,6 @@ cifs_parse_mount_options(const char *mountdata, const char *devname, */ vol->seal = 1; break; - case Opt_direct: - cache_specified = true; - vol->direct_io = true; - vol->strict_io = false; - cERROR(1, "The \"directio\" option will be removed in " - "3.7. Please switch to the \"cache=none\" " - "option."); - break; - case Opt_strictcache: - cache_specified = true; - vol->direct_io = false; - vol->strict_io = true; - cERROR(1, "The \"strictcache\" option will be removed " - "in 3.7. Please switch to the \"cache=strict\" " - "option."); - break; case Opt_noac: printk(KERN_WARNING "CIFS: Mount option noac not " "supported. Instead set " @@ -1771,7 +1751,6 @@ cifs_parse_mount_options(const char *mountdata, const char *devname, goto cifs_parse_mount_err; break; case Opt_cache: - cache_specified = true; string = match_strdup(args); if (string == NULL) goto out_nomem; @@ -1822,14 +1801,6 @@ cifs_parse_mount_options(const char *mountdata, const char *devname, printk(KERN_NOTICE "CIFS: ignoring forcegid mount option " "specified with no gid= option.\n"); - /* FIXME: remove this block in 3.7 */ - if (!cache_specified && !cache_warned) { - cache_warned = true; - printk(KERN_NOTICE "CIFS: no cache= option specified, using " - "\"cache=loose\". This default will change " - "to \"cache=strict\" in 3.7.\n"); - } - kfree(mountdata_copy); return 0;