Skip to content

Add constants for ioctl request codes #66887

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
serhiy-storchaka opened this issue Oct 22, 2014 · 3 comments
Open

Add constants for ioctl request codes #66887

serhiy-storchaka opened this issue Oct 22, 2014 · 3 comments
Assignees
Labels
extension-modules C modules in the Modules dir type-feature A feature request or enhancement

Comments

@serhiy-storchaka
Copy link
Member

BPO 22698
Nosy @pitrou, @serhiy-storchaka

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = None
closed_at = None
created_at = <Date 2014-10-22.15:12:03.213>
labels = ['extension-modules', 'type-feature']
title = 'Add constants for ioctl request codes'
updated_at = <Date 2015-07-21.07:22:52.829>
user = 'https://github.com/serhiy-storchaka'

bugs.python.org fields:

activity = <Date 2015-07-21.07:22:52.829>
actor = 'ethan.furman'
assignee = 'none'
closed = False
closed_date = None
closer = None
components = ['Extension Modules']
creation = <Date 2014-10-22.15:12:03.213>
creator = 'serhiy.storchaka'
dependencies = []
files = []
hgrepos = []
issue_num = 22698
keywords = []
message_count = 3.0
messages = ['229827', '229891', '238288']
nosy_count = 4.0
nosy_names = ['pitrou', 'neologix', 'serhiy.storchaka', 'mrl']
pr_nums = []
priority = 'normal'
resolution = None
stage = None
status = 'open'
superseder = None
type = 'enhancement'
url = 'https://bugs.python.org/issue22698'
versions = ['Python 3.5']

@serhiy-storchaka
Copy link
Member Author

It would be useful to expose ioctl request codes (Linux specific?) [1] at Python level.

In particular this will allow to determine MAC address in uuid at Python level without using ctypes or calling external programs. [2]

[1] http://man7.org/linux/man-pages/man2/ioctl_list.2.html
[2] http://code.activestate.com/recipes/439094-get-the-ip-address-associated-with-a-network-inter/

@serhiy-storchaka serhiy-storchaka added extension-modules C modules in the Modules dir type-feature A feature request or enhancement labels Oct 22, 2014
@neologix
Copy link
Mannequin

neologix mannequin commented Oct 23, 2014

Adding ioctl constants is fine.
However, I think that if we do this, it'd be great if we could also
expose this information in a module (since psutil inclusion was
discussed recently), but that's probably another issue.

@mrl
Copy link
Mannequin

mrl mannequin commented Mar 17, 2015

In addition to ioctl constants from Linux, it would also be very helpful
to add the constants from NetBSD et al. that are described in their ioctl(2) man page: http://man.netbsd.org/man/ioctl+2+NetBSD-current

Thank you!

@ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
@serhiy-storchaka serhiy-storchaka self-assigned this Apr 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
extension-modules C modules in the Modules dir type-feature A feature request or enhancement
Projects
None yet
Development

No branches or pull requests

1 participant