From patchwork Tue Mar 24 04:50:08 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sudip Mukherjee X-Patchwork-Id: 6077091 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 19C559F318 for ; Tue, 24 Mar 2015 04:50:23 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 3CE0520263 for ; Tue, 24 Mar 2015 04:50:22 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 1BA1720260 for ; Tue, 24 Mar 2015 04:50:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750906AbbCXEuU (ORCPT ); Tue, 24 Mar 2015 00:50:20 -0400 Received: from mail-pa0-f42.google.com ([209.85.220.42]:34599 "EHLO mail-pa0-f42.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751328AbbCXEuT (ORCPT ); Tue, 24 Mar 2015 00:50:19 -0400 Received: by pacwe9 with SMTP id we9so213544766pac.1; Mon, 23 Mar 2015 21:50:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=azTO3GhPPn3MtTtoptWv5xD+l0Hz5d6nPoALgEIPC9U=; b=a+HQTRUJd3rcer0shrwvSdBOE+eN/XiPOmjNeUqUDsMpPsk3ENi5OY0+hxP39r/1D7 21Dc0LpiFUryOMxdwsfCGL4AndKO7sLZzLWxs8EMWfaGR9WX4RkUd4lKMEbeMpyiwhW9 1GngpIZ1rxFwwIYMLeh9WZS4fRV8ILtTfj/XbaHlYh7Q5dVlOcAMKKMWr0SKTFXMi+SB vJ+J3Q2eN5e+Uzxf+Xsx/tECGM+Wo3P6zikFrIPandjJOl7BJRuZfdbyoyWv1a97JHej eHWeq39w7D4mtA+BcEcznEDVmA1O7SlimZD56cBnb2ZtCM838TIalnB7lEOqyWFsgrrE HKrA== X-Received: by 10.70.90.81 with SMTP id bu17mr4102369pdb.105.1427172619145; Mon, 23 Mar 2015 21:50:19 -0700 (PDT) Received: from localhost.localdomain ([122.169.163.246]) by mx.google.com with ESMTPSA id g10sm2665176pdm.29.2015.03.23.21.50.16 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 23 Mar 2015 21:50:18 -0700 (PDT) From: Sudip Mukherjee To: Greg Kroah-Hartman Cc: Sudip Mukherjee , linux-fbdev@vger.kernel.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/2] staging: sm7xxfb: start using module parameters Date: Tue, 24 Mar 2015 10:20:08 +0530 Message-Id: <1427172609-4318-1-git-send-email-sudipm.mukherjee@gmail.com> X-Mailer: git-send-email 1.8.1.2 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP add module parameters so that we can configure X and Y resolutions and bpp when using this driver as a module. Signed-off-by: Sudip Mukherjee --- drivers/staging/sm7xxfb/sm7xxfb.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/drivers/staging/sm7xxfb/sm7xxfb.c b/drivers/staging/sm7xxfb/sm7xxfb.c index abdb021..6e9b2aa 100644 --- a/drivers/staging/sm7xxfb/sm7xxfb.c +++ b/drivers/staging/sm7xxfb/sm7xxfb.c @@ -1033,6 +1033,24 @@ static int __init sm712fb_init(void) module_init(sm712fb_init); +module_param(mode_option, charp, S_IRUGO); + +MODULE_PARM_DESC(mode_option, "\n\t\tOptions:\n" + "\t\t0x301 = 640x480-8\n" + "\t\t0x303 = 800x600-8\n" + "\t\t0x305 = 1024x768-8\n" + "\t\t0x307 = 1280x1024-8\n" + "\t\t0x311 = 640x480-16\n" + "\t\t0x314 = 800x600-16\n" + "\t\t0x317 = 1024x768-16\n" + "\t\t0x31A = 1280x1024-16\n" + "\t\t0x312 = 640x480-24\n" + "\t\t0x315 = 800x600-24\n" + "\t\t0x318 = 1024x768-24\n" + "\t\t0x31B = 1280x1024-24\n" + "\t\tUsual example:\n" + "\t\tinsmod ./sm7xxfb.ko mode_option=\"0x301\"\n"); + static void __exit sm712fb_exit(void) { pci_unregister_driver(&smtcfb_driver);