/*
* This explicit cast to (s16) is necessary as the measurement
* is done in 2's complement with positive and negative values.
- * The follwing assignment to *val will then convert the signed
+ * The following assignment to *val will then convert the signed
* s16 value to a signed int value.
*/
*val = (s16)le16_to_cpu(hw_values[address]);
return ret;
}
data->cntl_cache = regval;
- /* After mode change wait atleast 100us */
+ /* After mode change wait at least 100us */
usleep_range(100, 500);
return 0;
return read_status;
}
-/* Returns 0 if the end of conversion interrupt occured or -ETIME otherwise */
+/* Returns 0 if the end of conversion interrupt occurred or -ETIME otherwise */
static int wait_conversion_complete_interrupt(struct ak8975_data *data)
{
int ret;
if (ret < 0)
goto exit;
- /* Read out ST2 for release lock on measurment data. */
+ /* Read out ST2 for release lock on measurement data. */
ret = i2c_smbus_read_byte_data(client, data->def->ctrl_regs[ST2]);
if (ret < 0) {
dev_err(&client->dev, "Error in reading ST2\n");
* as the values for [x, y1, y2]. The value is +/-31
* but the effect on the raw values is much larger.
* The effect of the offset is to bring the measure
- * rougly to the center.
+ * roughly to the center.
*/
ox = 0;
oy1 = 0;