From: Greg KH <gregkh@linuxfoundation.org>
To: Rajaram Regupathy <rajaram.regupathy@gmail.com>
Cc: linux-usb@vger.kernel.org, heikki.krogerus@linux.intel.com,
Benson Leung <bleung@google.com>,
Prashant Malani <pmalani@chromium.org>,
jthies@google.com, saranya.gopal@intel.com
Subject: Re: [ANNOUNCE] libtypec_0.1/lstypec_0.1 is released
Date: Mon, 17 Jan 2022 16:38:09 +0100 [thread overview]
Message-ID: <YeWNYUkOYBWXjBFw@kroah.com> (raw)
In-Reply-To: <CAD039W5ZmTcYErXsnSpdksc6k2L3fNwry1uP2Kr96Uo04fO9PQ@mail.gmail.com>
On Mon, Jan 17, 2022 at 08:07:58PM +0530, Rajaram Regupathy wrote:
> On Mon, Jan 17, 2022 at 12:48 PM Greg KH <gregkh@linuxfoundation.org> wrote:
> >
> > On Sun, Jan 16, 2022 at 08:49:47PM +0530, Rajaram Regupathy wrote:
> > > HI
> > >
> > > libtypec
> > > ++++++
> > >
> > > USB-Type C and USB Power Delivery systems are with multiple
> > > specification versions, platform designs and microcontroller vendors
> > > for managing data, power and display.
> > >
> > > libtypec is aimed to provide a generic way for userspace System
> > > Software on Linux, Android, Chrome OS or Other OSes to build developer
> > > tools or
> > > other management applications for USB-Type C and USB Power Delivery
> > > class devices.
> >
> > Great, can we add this to the usbutils package, and `lsusb`?
> Thanks. Yes, the goal is to have it in usbutils package. The thought
> to have lstypec outside lsusb is as follows :
>
> "lsusb" displays USB device details based on the USB device's "descriptors'' .
> lstypec is for displaying usb-c "port capability" and the usb-c
> partner "port/plug capabilities' ' and
> the information is agnostic to USB descriptor topology or USB bus.
> Ex: usb-c power adapters or usb-c display dongle or a usb-c e-cable etc..
>
> Open to hear your recommendations.
It's fine to keep it as a separate program to type, or you can make it
an option for 'lsusb' to output "lsusb --ports" or something?
As your code is pretty tiny, and only reads from sysfs, it shouldn't be
hard to integrate. But you do need to fix the license issue :)
> > > Features
> > > ======
> > > - libtypec - get method for port and port-partner capabilities
> > > - utils/lstypec - displaying information about USB typec class
> > > devices in the system and the devices connected to them
> > >
> > > Release:
> > > =======
> > >
> > > Binary : https://github.com/Rajaram-Regupathy/libtypec/releases/download/libtypec_v0.1/libtypec_0.1.tar.xz
> > > Source : https://github.com/Rajaram-Regupathy/libtypec/archive/refs/tags/libtypec_v0.1.tar.gz
> >
> > Like was pointed out, there is no license listed for this code, so no
> > one can use it.
> >
> > Also, it doesn't build for me:
>
> Could you please follow the Readme steps..?
>
> > $ make
> > 50%] Building C object CMakeFiles/lstypec.dir/lstypec.c.o
> > 100%] Linking C executable lstypec
> > usr/bin/ld: /home/gregkh/tmp/libtypec/bin/liblibtypec.a(libtypec.c.o):(.bss+0x0): multiple definition of `__packed'; CMakeFiles/lstypec.dir/lstypec.c.o:(.bss+0x0): first defined here
> > usr/bin/ld: /home/gregkh/tmp/libtypec/bin/liblibtypec.a(libtypec_sysfs_ops.c.o):(.bss+0x0): multiple definition of `__packed'; CMakeFiles/lstypec.dir/lstypec.c.o:(.bss+0x0): first defined here
> > ollect2: error: ld returned 1 exit status
> > ake[2]: *** [CMakeFiles/lstypec.dir/build.make:98: lstypec] Error 1
> > ake[1]: *** [CMakeFiles/Makefile2:839: CMakeFiles/lstypec.dir/all] Error 2
> > ake: *** [Makefile:121: all] Error 2
I did follow the readme steps, what did I miss?
If I delete the one instance of "__packed" from the project, it does
build for me. Perhaps you need to make sure that is defined in your
compiler flags?
> > Why does this need to be a library at all?
Again, why does this have to be a library?
thanks,
greg k-h
next prev parent reply other threads:[~2022-01-17 15:38 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-16 15:19 [ANNOUNCE] libtypec_0.1/lstypec_0.1 is released Rajaram Regupathy
2022-01-16 15:37 ` Stephan Brunner
2022-01-17 7:18 ` Greg KH
2022-01-17 14:37 ` Rajaram Regupathy
2022-01-17 15:38 ` Greg KH [this message]
2022-01-18 16:31 ` Rajaram Regupathy
2022-01-18 18:33 ` Greg KH
2022-01-18 19:16 ` Benson Leung
2022-01-19 8:28 ` Greg KH
2022-01-20 9:59 ` Rajaram Regupathy
2022-01-20 11:50 ` Greg KH
2022-01-26 16:09 ` Rajaram Regupathy
2022-01-26 16:39 ` Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=YeWNYUkOYBWXjBFw@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=bleung@google.com \
--cc=heikki.krogerus@linux.intel.com \
--cc=jthies@google.com \
--cc=linux-usb@vger.kernel.org \
--cc=pmalani@chromium.org \
--cc=rajaram.regupathy@gmail.com \
--cc=saranya.gopal@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).