Project

General

Profile

Bug #8627

want ddi_ffsll, ddi_flsll

Added by Hans Rosenfeld about 2 years ago. Updated about 2 years ago.

Status:
New
Priority:
Normal
Category:
kernel
Start date:
2017-09-07
Due date:
% Done:

0%

Estimated time:
Difficulty:
Bite-size
Tags:
needs-triage

Description

DDI currently provides ddi_ffs(long) and ddi_fls(long), both backed by ffs(intmax_t). It's therefore trivial to add ddi_ffsll(long long) and ddi_flsll(long long), which I need for porting linuxkpi.

History

#1

Updated by Hans Rosenfeld about 2 years ago

Webrev: https://grumpf.hope-2000.org/illumos-8627/

Testing: I took some random driver and added a bunch of calls to the old and new ffs/fls functions with various values in 32bit and 64bit integers and observed the values returned. The first/last bits set came out as expected, which isn't surprising as I didn't really change the underlying function, just added new wrappers.

This change has been in illumos-joyent since July.

Also available in: Atom PDF