From owner-svn-src-all@freebsd.org Mon Oct 3 17:20:36 2016 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 227E4AF3B57; Mon, 3 Oct 2016 17:20:36 +0000 (UTC) (envelope-from gonzo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id D77B83B4; Mon, 3 Oct 2016 17:20:35 +0000 (UTC) (envelope-from gonzo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u93HKZb3016806; Mon, 3 Oct 2016 17:20:35 GMT (envelope-from gonzo@FreeBSD.org) Received: (from gonzo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u93HKY7S016801; Mon, 3 Oct 2016 17:20:34 GMT (envelope-from gonzo@FreeBSD.org) Message-Id: <201610031720.u93HKY7S016801@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: gonzo set sender to gonzo@FreeBSD.org using -f From: Oleksandr Tymoshenko Date: Mon, 3 Oct 2016 17:20:34 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r306647 - in head/sys/dev: evdev usb/input X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Oct 2016 17:20:36 -0000 Author: gonzo Date: Mon Oct 3 17:20:34 2016 New Revision: 306647 URL: https://svnweb.freebsd.org/changeset/base/306647 Log: const-ify struct evdev_methods Submitted by: Vladimir Kondratiev Suggested by: hselasky Modified: head/sys/dev/evdev/evdev.c head/sys/dev/evdev/evdev.h head/sys/dev/evdev/evdev_private.h head/sys/dev/usb/input/ukbd.c head/sys/dev/usb/input/ums.c Modified: head/sys/dev/evdev/evdev.c ============================================================================== --- head/sys/dev/evdev/evdev.c Mon Oct 3 16:47:46 2016 (r306646) +++ head/sys/dev/evdev/evdev.c Mon Oct 3 17:20:34 2016 (r306647) @@ -302,7 +302,7 @@ evdev_set_serial(struct evdev_dev *evdev inline void evdev_set_methods(struct evdev_dev *evdev, void *softc, - struct evdev_methods *methods) + const struct evdev_methods *methods) { evdev->ev_methods = methods; Modified: head/sys/dev/evdev/evdev.h ============================================================================== --- head/sys/dev/evdev/evdev.h Mon Oct 3 16:47:46 2016 (r306646) +++ head/sys/dev/evdev/evdev.h Mon Oct 3 17:20:34 2016 (r306647) @@ -89,7 +89,8 @@ void evdev_set_name(struct evdev_dev *, void evdev_set_id(struct evdev_dev *, uint16_t, uint16_t, uint16_t, uint16_t); void evdev_set_phys(struct evdev_dev *, const char *); void evdev_set_serial(struct evdev_dev *, const char *); -void evdev_set_methods(struct evdev_dev *, void *, struct evdev_methods *); +void evdev_set_methods(struct evdev_dev *, void *, + const struct evdev_methods *); int evdev_register(struct evdev_dev *); int evdev_unregister(struct evdev_dev *); int evdev_push_event(struct evdev_dev *, uint16_t, uint16_t, int32_t); Modified: head/sys/dev/evdev/evdev_private.h ============================================================================== --- head/sys/dev/evdev/evdev_private.h Mon Oct 3 16:47:46 2016 (r306646) +++ head/sys/dev/evdev/evdev_private.h Mon Oct 3 17:20:34 2016 (r306647) @@ -116,7 +116,7 @@ struct evdev_dev uint64_t ev_report_count; /* Parent driver callbacks: */ - struct evdev_methods * ev_methods; + const struct evdev_methods * ev_methods; void * ev_softc; LIST_ENTRY(evdev_dev) ev_link; Modified: head/sys/dev/usb/input/ukbd.c ============================================================================== --- head/sys/dev/usb/input/ukbd.c Mon Oct 3 16:47:46 2016 (r306646) +++ head/sys/dev/usb/input/ukbd.c Mon Oct 3 17:20:34 2016 (r306647) @@ -364,7 +364,7 @@ static device_detach_t ukbd_detach; static device_resume_t ukbd_resume; #ifdef EVDEV_SUPPORT -static struct evdev_methods ukbd_evdev_methods = { +static const struct evdev_methods ukbd_evdev_methods = { .ev_event = evdev_ev_kbd_event, }; #endif Modified: head/sys/dev/usb/input/ums.c ============================================================================== --- head/sys/dev/usb/input/ums.c Mon Oct 3 16:47:46 2016 (r306646) +++ head/sys/dev/usb/input/ums.c Mon Oct 3 17:20:34 2016 (r306647) @@ -191,7 +191,7 @@ static struct usb_fifo_methods ums_fifo_ }; #ifdef EVDEV_SUPPORT -static struct evdev_methods ums_evdev_methods = { +static const struct evdev_methods ums_evdev_methods = { .ev_open = &ums_ev_open, .ev_close = &ums_ev_close, };