- patches.apparmor/remove_suid_new_case_in_2.6.22.diff: Merge fix.
[linux-flexiantxendom0-3.2.10.git] / drivers / media / video / msp3400-driver.c
index ba1af3c..3bb7d66 100644 (file)
@@ -773,6 +773,9 @@ static int msp_command(struct i2c_client *client, unsigned int cmd, void *arg)
                break;
        }
 
+       case VIDIOC_G_CHIP_IDENT:
+               return v4l2_chip_ident_i2c_client(client, arg, state->ident, (state->rev1 << 16) | state->rev2);
+
        default:
                /* unknown */
                return -EINVAL;
@@ -872,6 +875,8 @@ static int msp_attach(struct i2c_adapter *adapter, int address, int kind)
        snprintf(client->name, sizeof(client->name), "MSP%d4%02d%c-%c%d",
                        msp_family, msp_product,
                        msp_revision, msp_hard, msp_rom);
+       /* Rev B=2, C=3, D=4, G=7 */
+       state->ident = msp_family * 10000 + 4000 + msp_product * 10 + msp_revision - '@';
 
        /* Has NICAM support: all mspx41x and mspx45x products have NICAM */
        state->has_nicam = msp_prod_hi == 1 || msp_prod_hi == 5;